自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(5)
  • 收藏
  • 关注

原创 C语言 数组 实现三子棋小游戏

//game.h#define ROW 3#define COL 3#include<stdio.h>#include<stdlib.h>#include<time.h>//声明void initBoard(char board[ROW][COL],int row,int col);void DisplayBoard(char board[ROW][COL],int row,int col);void PlayerMove(char board[R.

2021-08-05 14:46:30 136

原创 冒泡排序 升序

#include<stdio.h>void bubble_sort(int arr[],int sz){ int i=0; for(i=0;i=sz-1;i++) i<sz-1写错了,找了很久才找到 { int j=0; for(j=0;j<sz-1-i;j++) { if(arr[j]>arr[j+1]) { int t...

2021-08-02 19:49:27 51

原创 题目:打印闰年

思路:四年一闰年,百年不闰,四百年再闰#include<stdio.h>int main(){ int year=0; for(year=1000;year<2000;year++) { 、//if(year%4==0&&year%100!=0) { // printf("%d ",year); } // else if(year%400==0) ...

2021-07-21 11:39:28 60

原创 题目:两数最大公约数

思路:辗转相除法#include<stdio.h>int main(){ int m=0; int n=0; int r=0; scanf("%d%d",&m,&n); while(m%n) //m%n==0为假,不进入循环 { r=m%n; m=n; n=r; } printf("%d",r); return 0;}...

2021-07-21 11:25:25 58

原创 名称:三个数从大到小输出

#include <stdio.h>int main(){ int a=0; int b=0; int c=0; scanf("%d%d%d",&a,&b,&c);//算法实现 a放最大值 b次之 c最小 if(a<c) { int tmp=a; a=c; c=tmp; } if(a<b) { int tmp=a;...

2021-07-21 11:13:19 65

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除