编写题解 1670: 拆分位数 摘要:解题思路: 先定义一个整数n,并输入他的值,然后再分别拆分出百位、十位和个位(例:365/100=3……65 即百位为3;65/10=6……5 即十位为6;5/1=5 即个位为5),最后按照题目要…… 题解列表 2024年01月22日 1 点赞 0 评论 103 浏览 评分:0.0
拆分位数 (C语言代码) 摘要:#include <stdio.h> #define Pi 3.1415 int main() { int x,y,z,a; scanf("%d",&a); x=a%10; y…… 题解列表 2017年12月11日 0 点赞 0 评论 606 浏览 评分:0.0
1670: 拆分位数 摘要:解题思路:注意事项:参考代码:#include <iostream> using namespace std; int main() { int n = 0; cin >>…… 题解列表 2022年10月09日 0 点赞 0 评论 83 浏览 评分:0.0
拆分位数 (C语言代码) 摘要:会用%符号求余注意事项:空格别忘了参考代码:#include<stdio.h>int main(){ int a,b,c,d; scanf("%d",&d); c=d%10; b=(d%100-c)/…… 题解列表 2018年02月27日 0 点赞 0 评论 497 浏览 评分:0.0
拆分位数《三位数》 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int n; cin>>n; cout<<n%10<…… 题解列表 2024年12月01日 0 点赞 0 评论 222 浏览 评分:0.0
拆分位数 (C语言代码) 摘要:解题思路:此题涉及到运用%和/运算符的运用,一个三位数的个位可以用n%10求得,十位数可以用n%100/10求得,百位数可以用n/100,求得,因为整数除以整数得到的仍然是一个整数注意事项:首先判断输…… 题解列表 2018年11月16日 1 点赞 0 评论 478 浏览 评分:0.0
拆分位数 (Java代码) 摘要:解题思路:注意事项:参考代码:import java.util.*;public class z1670 { public static void main(String[]args){ Scann…… 题解列表 2018年04月22日 0 点赞 0 评论 565 浏览 评分:0.0
拆分位数-题解<简单粗暴>(C语言代码) 摘要:这题主要是“个位”十位“百位的提取。(%的意思取余数) 个位简单//因为是3位数的,所以个位就是n/100就可以得到了(n是输入的数) 十位//可以n%100/10;还有n/10%10; 百位/…… 题解列表 2020年02月21日 0 点赞 0 评论 421 浏览 评分:0.0
1670: 拆分位数 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int n,a,b,c; cin>>n; c=n%10; b=n%10…… 题解列表 2023年01月26日 0 点赞 0 评论 87 浏览 评分:0.0
拆分位数-题解(C语言代码) 摘要:解题思路:拆分位数注意事项:输出结果参考代码:#include<stdio.h>int main(){ int a; scanf("%d",&a); printf("%d %d %d…… 题解列表 2020年11月27日 0 点赞 0 评论 163 浏览 评分:0.0