码迷,mamicode.com
首页 >  
搜索关键字:状态机 有穷自动机 printf    ( 16150个结果
指针联系
前三题: #include<stdlib.h> #include<time.h> void bubble(int* px); void chioce(int* q); void del(int n, int len, int* py); int main() { int a[10], * p, b[ ...
分类:其他好文   时间:2020-12-22 11:53:06    阅读次数:0
例子2
#include<stdio.h>/当fahr=0,20,……,300时,分别打印华氏温度与摄氏温度对照表/intmain(){printf("摄氏温度-华氏温度对照表\n");intfahr;for(fahr=300;fahr>=0;fahr=fahr-20){printf("%3d%6.1f\n",fahr,(5.0/9.0)(fahr
分类:其他好文   时间:2020-12-22 11:43:41    阅读次数:0
获取 goroutineID
本文转自鸟窝 获取 goroutineID package main import ( "fmt" "runtime" "strconv" "strings" "sync" ) func GoID() int { var buf [64]byte n := runtime.Stack(buf[:], ...
分类:其他好文   时间:2020-12-21 11:47:58    阅读次数:0
三个数按大小顺序输出
#include<stdio.h>intmain(){inta=0;intb=0;intc=0;scanf("%d%d%d",&a,&b,&c);if(a<b){inttmp=a;a=b;b=tmp;}if(a<c){inttmp=a;a=c;c=tmp;}if(b<c){inttmp=b;b=c;c=tmp;}printf
分类:其他好文   时间:2020-12-21 11:13:40    阅读次数:0
最大公约数
#include<stdio.h>intmain(){intm=24;intn=18;intr=0;while(m%n){r=m%n;m=n;n=r;}printf("%d\n",n);return0;}
分类:其他好文   时间:2020-12-21 11:13:24    阅读次数:0
打印闰年 打印素数
//打印闰年#include<stdio.h>intmain(){intyear=0;intcount=0;for(year=1000;year<=2000;year++){if(year%4==0&&year%100!=0){printf("%d",year);count++;}elseif(year%400==0){printf("%d",year);coun
分类:其他好文   时间:2020-12-21 11:12:56    阅读次数:0
打印闰年 打印素数
//打印闰年#include<stdio.h>intmain(){intyear=0;intcount=0;for(year=1000;year<=2000;year++){if(year%4==0&&year%100!=0){printf("%d",year);count++;}elseif(year%400==0){printf("%d",year);coun
分类:其他好文   时间:2020-12-21 11:12:41    阅读次数:0
一个关于字符串的c语言程序
源程序: #include <stdio.h>#include <string.h> int main(){ char str[20]; int length; length=strlen(strcpy(str,"Hello World!")); printf("字符串长度:%d\n",length ...
分类:编程语言   时间:2020-12-19 12:52:11    阅读次数:5
函数的秘密之 形参和实参
C 语言自学之 形参和实参 1 #include <stdlib.h> 2 3 int getGirth(int a,int b,int c) 4 { 5 if( (a+b)<=c || (a+c)<=b || (b+c)<=a ) //判断是否为三角形 6 { 7 printf("不构成三角形\n ...
分类:其他好文   时间:2020-12-18 12:48:09    阅读次数:4
sh脚本例子
#!/bin/bashecho "第一个参数为: $1";echo "参数个数为: $#";echo "表示执行脚本传入参数的列表 $*"; sh demo.sh 111 222 3331、$# 表示执行脚本传入参数的个数2、$* 表示执行脚本传入参数的列表(不包括$0)3、$$ 表示进程的id4、 ...
分类:其他好文   时间:2020-12-18 12:35:42    阅读次数:2
16150条   上一页 1 ... 22 23 24 25 26 ... 1615 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!