摘要: #include<stdio.h> #include<stdlib.h> int main(){ FILE *fp; char al; int count=0; fp=fopen("C:\\data4.txt","r"); if(fp==NULL){ printf("fail to open fil 阅读全文
posted @ 2022-12-28 10:20 WA自动机! 阅读(18) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h> #include<stdlib.h> #include <string.h> #define N 5 typedef struct student { char name[10]; int num; int maths; int computer; int en 阅读全文
posted @ 2022-12-28 10:15 WA自动机! 阅读(21) 评论(0) 推荐(0) 编辑
摘要: 实验一 #include <stdio.h> #define N 4 #include <stdlib.h> int main() { int a[N] = {1, 9, 8, 4}; char b[N] = {'1', '9', '8', '4'}; int i; printf("sizeof(i 阅读全文
posted @ 2022-11-26 21:00 WA自动机! 阅读(5) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h> #include<stdlib.h> #include<time.h> #include<windows.h> #define N 80 void print_text(int line, int col, char text[]);//*函数声明*// void 阅读全文
posted @ 2022-11-06 19:07 WA自动机! 阅读(45) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h> #include<stdlib.h> #include<time.h> #define N 5 int main() { int i,number; srand(time(0)); for(i=0;i<=N;++i) { number=rand()%500+1; 阅读全文
posted @ 2022-10-31 19:10 WA自动机! 阅读(26) 评论(0) 推荐(0) 编辑
摘要: 实验一 #include <stdio.h> int main() { printf(" O \n"); printf("<H>\n"); printf("I I\n"); printf(" O \n"); printf("<H>\n"); printf("I I\n"); return 0; #i 阅读全文
posted @ 2022-10-16 15:47 WA自动机! 阅读(49) 评论(0) 推荐(0) 编辑
摘要: from turtle import *def square(size=50, c='pink'): pencolor(c) for i in range(4): fd(size) left(90)def main(): setup(800, 600) speed(0) n = 10 for i i 阅读全文
posted @ 2022-06-13 20:20 WA自动机! 阅读(40) 评论(1) 推荐(0) 编辑
摘要: class User: def __init__(self, name='guest', password='111111', status='1'): self.name=name self.password=password self.status=status def modify_passw 阅读全文
posted @ 2022-06-05 22:26 WA自动机! 阅读(29) 评论(1) 推荐(0) 编辑
摘要: def is_valid(x): if len(x[1])==18 and (x[1][:-1].isdigit() and x[1][-1] in '0123456789X'): return True return Falsewith open('data3_id.txt','r',encodi 阅读全文
posted @ 2022-05-24 13:26 WA自动机! 阅读(49) 评论(1) 推荐(0) 编辑
摘要: with open('data3.txt','r',encoding='utf-8')as f: data=f.read().split('\n') list1=data[1:11] print("原始数据:") print(list1) list2=[] for i in list1: num=f 阅读全文
posted @ 2022-05-16 23:18 WA自动机! 阅读(64) 评论(1) 推荐(0) 编辑