c中的模式和转换 [英] Pattern and conversion in c

查看:76
本文介绍了c中的模式和转换的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何将二进制数转换为十进制数,八进制数和十六进制数,以及打印模式如

----------

1

12

234

3456

56789

________

how to convert binary number into Decimal,Octal and Hexadecimal and also print pattern like
----------
1
12
234
3456
56789
________

推荐答案

我认为你应该编写一个算法来改变基于价格,然后用\ nn编写你的输出
i think you should write an algorithm to change the Prices based and then write your output with "\n"


这不是CP通常的工作方式。这里最重要的目标是学习和帮助学习。

你应该自己尝试,当你遇到困难时来到这里,对你的代码,设计等有一个具体的问题。



请查看你有什么尝试? [ ^ ]看看我的意思是一个很好的解释。



不要忘记这里的人不会得到报酬。此外,如果我们给你一个现成的解决方案,它不会帮助你,因为你不会从中学到任何东西。
This is not how CP usually works. Most important goal here is to learn and help learning.
You are supposed to try it on your own, and come here when you got stuck with something, with a concrete question about your code, design, etc.

Please have a look to What have you tried?[^] to see a good explanation about what I mean.

Don't forget people here don't get payed. And besides, if we give you a ready-to-go solution, it is not going to help you because you are not going to learn anything from it.


这篇关于c中的模式和转换的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆