随笔分类 - 算法竞赛习题
摘要:方法一:用C语言中自带的绝对值函数表示: 如果a是整数: abs() 如果a是浮点数: double型 fabs() 方法二:自己编写一个函数表示:
阅读全文
摘要:strcpy 函数 其余常见函数 stringstream C++ isalpha、isalnum、islower、isupper
阅读全文
摘要:题目地址 scanf() 遇到空格结束输入 可以用 scanf("%[^\n]" , str) 输入一行数据包括空格,直到遇到换行符 ' \n '
阅读全文
摘要:#include<stdio.h> void getW(int x){ while(x != 0){ int d = x %10; printf("%d ",d); x /= 10; } printf("\n"); } int main(){ int n; while(true){ scanf("%d",&n); getW(n); } return 0; }
阅读全文
摘要:__64 关键字 大数问题 根据输入的正整数n控制输出的格式
阅读全文