码迷,mamicode.com
首页 >  
搜索关键字:scanf    ( 10388个结果
实验4
任务1 可是使用数组变量和指针变量 任务2 //2.1 #include<stdio.h> long long fac(int n); int main(){ int i,n; printf("Enter n:"); scanf("%d",&n); for(i=1;i<=n;i++) printf( ...
分类:其他好文   时间:2020-12-03 11:47:34    阅读次数:4
实验4
#include <math.h> #include <stdio.h> void solve(double a, double b, double c); int main() { double a, b, c; printf("Enter a, b, c: "); while(scanf("%l ...
分类:其他好文   时间:2020-12-02 12:36:07    阅读次数:9
sscanf()的使用
sscanf()的使用 函数原型: int sscanf( const char *buffer, const char *format [, argument ] ... ); ...表示是一个多参函数,其实就和scanf是一样的,只是从命令行变成了从str中读取 针对于第二个const char ...
分类:其他好文   时间:2020-12-01 11:51:35    阅读次数:2
#2567. 「APIO2016」划艇
由于值域过大,考虑离散化,这样形成若干区间,对于每个人来说每段区间要么全部可选,要么全部不可选。 考虑递推,设 \(f_{i,j}\) 为前 \(i\) 所学校,最后一所参赛学校的数量不超过区间 \(j\) 的方案数,\(g_{i,j}\) 为前 \(i\) 所学校,最后一所参赛学校的数量在区间 \ ...
分类:Windows程序   时间:2020-11-26 14:54:50    阅读次数:15
网络流建图总结
1. P2065 [TJOI2011]卡片 桌子上现在有m张蓝色卡片和n张红色卡片,每张卡片上有一个大于1的整数。现在你要从桌子上拿走一些卡片,分若干次拿。每次只能拿走一组卡片:这组卡片颜色不同,并且两张卡片上面的数字的最大公约数大于1。问:最多可以从桌上拿走多少张卡片。 直接建图应该是可以的,但是 ...
分类:其他好文   时间:2020-11-26 14:51:15    阅读次数:4
实验三
#include<math.h> #include<stdio.h> int main(){ float a,b,c,x1,x2; float delta,real,imag; printf("Enter a,b,c:"); while(scanf("%f%f%f",&a,&b,&c)!=EOF){ ...
分类:其他好文   时间:2020-11-24 12:17:23    阅读次数:9
2020计算机C语言
8 1 #include<stdio.h> 2 int num[100]; 3 int main() 4 { 5 int x; 6 int cnt = 0; 7 scanf("%d", &x); 8 while(x) { 9 num[++cnt] = x % 10; 10 x = x / 10; 1 ...
分类:编程语言   时间:2020-11-24 12:15:10    阅读次数:9
一顿操作猛如虎,一看头发。。。
#include <math.h> #include <stdio.h> int main() { float a, b, c, x1, x2; float delta, real, imag; printf("Enter a, b, c: "); while(scanf("%f%f%f", &a, ...
分类:其他好文   时间:2020-11-24 12:14:01    阅读次数:6
实验3
实验任务4#include<stdio.h> #include<math.h> int main() { int n,a,b,i,s; printf("Enter a number:"); scanf("%d",&n); while(n){ i=0; s=0; while(n!=0){ a=n%10 ...
分类:其他好文   时间:2020-11-23 12:22:09    阅读次数:3
实验二
#include "stdafx.h" #include <stdio.h> int main(int argc, char* argv[]) { char a,b,c,d,e; scanf("%c%c%c%c%c",&a,&b,&c,&d,&e); putchar(a); putchar(b); ...
分类:其他好文   时间:2020-11-23 12:14:20    阅读次数:5
10388条   上一页 1 ... 13 14 15 16 17 ... 1039 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!