Auto commit
This commit is contained in:
		
							parent
							
								
									0b308fc718
								
							
						
					
					
						commit
						dcf8569b07
					
				
							
								
								
									
										17
									
								
								2207/C语言同步练习源码/3.数组-4.c
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								2207/C语言同步练习源码/3.数组-4.c
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,17 @@ | ||||
| #include <stdio.h> | ||||
| #include <time.h> | ||||
| #include <stdlib.h> | ||||
| 
 | ||||
| int main(){ | ||||
| 	int num[10], i; | ||||
| 	srand((unsigned)time(NULL)); | ||||
| 	 | ||||
| 	for(i=0;i<10;i++){ | ||||
| 		num[i] = rand()%101; | ||||
| 		printf("%d ", num[i]); | ||||
| 	} | ||||
| 	printf("\n"); | ||||
| 
 | ||||
| 	return 0; | ||||
| } | ||||
| 
 | ||||
| @ -540,13 +540,29 @@ int main(){ | ||||
| } | ||||
| ``` | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
| ### 数组-4 | ||||
| 
 | ||||
|  | ||||
| 
 | ||||
| ```c | ||||
| #include <stdio.h> | ||||
| #include <time.h> | ||||
| #include <stdlib.h> | ||||
| 
 | ||||
| int main(){ | ||||
| 	int num[10], i; | ||||
| 	srand((unsigned)time(NULL)); | ||||
| 	 | ||||
| 	for(i=0;i<10;i++){ | ||||
| 		num[i] = rand()%101; | ||||
| 		printf("%d ", num[i]); | ||||
| 	} | ||||
| 	printf("\n"); | ||||
| 
 | ||||
| 	return 0; | ||||
| } | ||||
| 
 | ||||
| ``` | ||||
| 
 | ||||
| ### 数组-5 | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user