码迷,mamicode.com
首页 >  
搜索关键字:pause    ( 1331个结果
video 与 audio
Play方法:使用play方法来播放媒体,自动将元素的paused属性的值变为false。Pause方法:使用pause方法来暂停播放,自动将元素的paused属性的值变为true。Load方法:使用load方法来重新载入媒体进行播放,自动将元素的playbackRate属性值变为defaultPl...
分类:其他好文   时间:2015-12-20 19:12:43    阅读次数:223
实时控制软件设计第二次编程作业
1 #include 2 #include"robot.h" 3 /* run this program using the console pauser or add your own getch, system("pause") or input loop */ 4 5 int ...
分类:其他好文   时间:2015-12-19 23:06:28    阅读次数:238
2015-12-18 学习心得
今天学习了c语言的一些库函数用法。比如:strcpy(),strlen(),strchr(),strcmp(),strcat(),strstr()。下面是我写的一些代码和结果。1.strlen#include<stdio.h> #include<string.h> intmain() { chara[10]="12345"; printf("%d\n",strlen(a)); system("pause"); r..
分类:其他好文   时间:2015-12-18 19:08:24    阅读次数:174
[pj2015题解]其实是纯代码.
第一题,很水,直接上代码 1 #include 2 #include 3 #include 4 /* run this program using the console pauser or add your own getch, system("pause") or input loop *...
分类:其他好文   时间:2015-12-17 13:00:53    阅读次数:234
strcat strcpy strcmp strlwr strlen的简单用法
#include<stdio.h>intmain(){charstr1[20]={"hello"};charstr2[]={"bit"};printf("%s",strcat(str1,str2));system("pause");return0;}#include<stdio.h>intmain(){charstr1[20];charstr2[]={"bit"};printf("%s",strcpy(str1,str2));system("pause");return0;}#incl..
分类:其他好文   时间:2015-12-16 17:30:15    阅读次数:218
求1!+2!+·····10!
#include<stdio.h>intmain(){ inti=0,sum=0,n=1,tmp=1; for(n=1;n<11;n++) { tmp=1; for(i=1;i<=n;i++) { tmp*=i; } sum+=tmp; } printf("%d\n",sum); system("pause"); return0;}这个代码很罗嗦非常不好可以优化为#include<stdio.h>intmain(){ inti=..
分类:其他好文   时间:2015-12-15 16:04:08    阅读次数:127
输出一个整数的每一位
#include<stdio.h> intmain() { inti=0,n=0; printf("请输入数字:"); scanf("%d",&i); while(i) { n=i%10; i=i/10; printf("%d",n); } system("pause"); return0; }
分类:其他好文   时间:2015-12-15 16:02:40    阅读次数:180
让我想输出的字符串 从两端向中间汇聚
#include<stdio.h> #include<windows.h> intmain() { charch[]=""; chara[]="1234567890"; inti=0,j=9; while(i<=j) { ch[i]=a[i]; ch[j]=a[j]; printf("%s\n",ch); Sleep(2000); i++; j--; } system("pause"); return0; }
分类:其他好文   时间:2015-12-14 06:53:38    阅读次数:179
求Sn=a+aa+aaa+aaaa+aaaaa的前5项之和,其中a是一个数字,例如:2+22+222+2222+22222
#include<stdio.h>intmain(){inta=0;intn=0;intsum=0;inttmp=0;inti=0;scanf("%d%d",&a,&n);for(i=0;i<n;i++){tmp=a+tmp*10;sum=sum+tmp;}printf("sum=%d",sum);system("pause");return0;}
分类:其他好文   时间:2015-12-13 23:59:26    阅读次数:318
交换两个数的值以及不使用临时变量交换两个数的值
使用临时变量非常简单#include<stdio.h>intmain(){ inta=1,b=2,c=0; printf("a="); scanf("%d",&a); printf("b="); scanf("%d",&b); c=a; a=b; b=c; printf("a=%d,b=%d\n",a,b); system("pause"); return0;}这时候我考虑可不可以不加入临时变量而同样达到目的呢..
分类:其他好文   时间:2015-12-11 07:18:07    阅读次数:124
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!