-
数根
数也有根吗?有!数根就是把一个数的各个数位上的值相加,直到得到一个一位数为止。请你编写一个程序来计算任意数N(0≤N≤1000000000000)的...
数根
数也有根吗?有!数根就是把一个数的各个数位上的值相加,直到得到一个一位数为止。请你编写一个程序来计算任意数N(0≤N≤1000000000000)的根。
输入:
输入有多个案例。每一个案例为一行,每行只有一个整数N。当输入的N是-1时,输入结束。
输出:
每一个案例输出一行。每行只有一个数字,就是N对应的数根。
Sample input
39
-1
Sample output
3-Number of root number also has roots do? There is! The number of roots is to a number of different values on the digital sum until they have been a number of up to one. Please write a program to calculate an arbitrary number N (0 ≤ N ≤ 1000000000000) roots. Input: Enter a number of cases. Each case for the line, each line is only an integer N. When the input of N is-1, the input end. Output: the output line of each case. There is only one number per line, that is, N corresponds to the number of roots. Sample input 39-1 Sample output 3
- 2023-09-05 21:25:03下载
- 积分:1
-
一个MP3程序的源代码,有动态显示屏,带控件 希望大家喜欢!
一个MP3程序的源代码,有动态显示屏,带控件 希望大家喜欢!-a program"s source code, a dynamic screen, with controls hope you like them!
- 2022-03-09 13:14:23下载
- 积分:1
-
求把6种物品(1*1,2*2....6*6)放入6*6的盒子里,最少用几个盒子
求把6种物品(1*1,2*2....6*6)放入6*6的盒子里,最少用几个盒子-keep the six items (1* 2* 2* 6 .... 6) Add 6* 6 box, for at least several boxes
- 2022-09-25 06:40:02下载
- 积分:1
-
教室灯控系统
本设计针对教室灯光的控制,分析了教室灯光控制的原理和实现方法,提出了基于单片机设计教室灯光智能控制系统的思路,并在此基础上开发了控制系统的硬件模块和相应的软件部分,以及添加了几项有用的功能,使该系统变得智能化。
- 2022-03-14 20:40:38下载
- 积分:1
-
1用Visual C++开发的战棋游戏(源代码)
一个用Visual C++开发的象棋对战游戏(含源码)-1 with Visual C++ development Chess Battle Game (with source code)
- 2022-03-12 07:06:15下载
- 积分:1
-
this a test program
this a test program-this is a test program.........
- 2022-02-10 16:48:13下载
- 积分:1
-
Achieved a convolution coding and Viterbi decoding, but also a simple BPSK modul...
实现了卷积编码和维特比译码,也有简单的BPSK调制解调过程。-Achieved a convolution coding and Viterbi decoding, but also a simple BPSK modulation and demodulation process.
- 2022-01-31 01:09:18下载
- 积分:1
-
完整的周立功公司的LPC213X开发板的光盘内容
完整的周立功公司的LPC213X开发板的光盘内容 -Ligong complete week
- 2022-12-15 12:10:04下载
- 积分:1
-
用VB编写的关机控件
用VB编写的关机控件-VB prepared by the shutdown controls
- 2022-03-25 07:38:37下载
- 积分:1
-
long time before the commencement of a time machine operation of the cpu
很久前作的一个启动机器时候的cpu运行情况-long time before the commencement of a time machine operation of the cpu
- 2022-03-20 00:46:29下载
- 积分:1