实验
XMUOJ 2023C++实验课
XMUOJ 有的题真够恶心的。在此总结一下,同时造福后人。 厦大GPA 某位同学一共参加了4门考试,给定四门考试的总分,请问在最优情况下,4门考试绩点的和最高是多少? 分情况讨论:一门合格,两门合格,三门合格或者四门合格,只用考虑当前门合格的情况。(不然会超时) 点击查看代码 #include <b ......
实验2
实验1:生成随机码 问题:1.生成586 ~701之间的随机数 2.生成202283300586~202283300701的随机码 #include<stdio.h> #include<stdlib.h> #include<time.h> #define N 5 #define R1 586 #de ......
实验2
#include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 #define R1 586 #define R2 701 int main() { int number; int i; srand(time(0)); for ......
实验2
2.1#include <stdio.h> #include <stdlib.h> #include <time.h> #define N 6 #define R1 586 #define R2 701 int main() { int number; int i; srand(time(0)); ......
实验2
task1 源代码 #include<stdio.h> #include<stdlib.h> #include<time.h> #define N 5 #define R1 586 #define R2 701 int main(){ int number; int i; srand(time(0) ......
实验2
实验任务1 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 #define R1 586 #define R2 701 int main() { int number; int i; srand( time(0 ......
实验2 字符串和列表
1.实验任务1 实验源码 task_1: #字符串的基础操作 x = 'nba FIFA' print(x.upper()) #字符串转大写 print(x.lower()) #字符串转小写 print(x.swapcase()) #字符串大小写翻转 print() x = 'abc' print( ......
3.16实验2
任务1 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 #define R1 586 #define R2 701 int main() { int number; int i; srand( time(0) ......
实验一 密码引擎-1-OpenEuler-OpenSSL编译
任务详情 0. 安装Ubuntu和OpenEuler虚拟机 1. 下载最新的OpenSSL源码(1.1版本) 2. 用自己的8位学号建立一个文件夹,cd 你的学号,用pwd获得绝对路径 3. 参考https://www.cnblogs.com/rocedu/p/5087623.html先在Ubunt ......
实验2 字符串与列表
1 x='nba FIFA' 2 print(x.upper()) 3 print(x.lower()) 4 print(x.swapcase()) 5 print() 6 7 x='abc' 8 print(x.center(10,'*')) 9 print(x.ljust(10,'*')) 10 ......
实验2
task1 x = 'phone_number' print(x.isidentifier()) x = '222test' print(x.isidentifier()) print() x = ' ' print(x.isspace()) x = '\n' print(x.isspace()) ......
实验2 字符串和列表
1.实验任务1 task1.py 程序源代码: 1 x = 'nba FIFA' 2 print(x.upper()) 3 print(x.lower()) 4 print(x.swapcase()) 5 print() 6 7 x = 'abc' 8 print(x.center(10, '*') ......
实验2 字符串和列表
实验任务1 task1.py 实验源码: x = 'nba FIFA' print(x.upper()) print(x.lower()) print(x.swapcase()) print() x = 'abc' print(x.center(10,'*')) print (x.ljust(10, ......
实验2
x = 'nba FIFA' print(x.upper()) print(x.lower()) print(x.swapcase()) print() x = 'abc' print(x.center(10,'*')) print(x.ljust(10,'*')) print(x.rjust(10 ......
实验2 字符串和列表
1. 实验任务1 task1.py 1 # 字符串的基础操作 2 # 课堂上没有演示的一些方法 3 x = 'nba FIFA' 4 print(x.upper()) # 字符串转大写 5 print(x.lower()) # 字符串转小写 6 print(x.swapcase()) # 字符串大小 ......
实验2
实验任务1 问题一:line18将几个随机数组合起来 问题二:根据当时的电脑时间,随机生成四个四位数 实验任务2 #include<stdio.h> #include<stdlib.h> int main() { double x, y; char c1, c2, c3; int a1, a2, a ......
实验二
task1 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 #define R1 586 #define R2 701 int main() { int number; int i; srand( time(0 ......
2023年3月22日【实验二】吴曦远
task1.py 源代码: x = 'nba FIFA' print(x.upper()) # 字符串转大写 print(x.lower()) # 字符串转小写 print(x.swapcase()) # 字符串大小写翻转 x = 'abc' print(x.center(10, '*')) # 字 ......
SYNU PTA C++ 第二章实验题
本随笔仅提供参考,具体题目请见PTA 7-1 测试C++ 1 #include "iostream" 2 #include "vector" 3 using namespace std; 4 int main(){ 5 int n; 6 cin>>n; 7 vector<int> nums(n); ......
实验二
task1 x = 'nba FIFA' print(x.upper()) print(x.lower()) print(x.swapcase()) print() x = 'abc' print(x.center(10, '*')) print(x.ljust(10, '*')) print(x. ......
实验任务二
任务一 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 6 #define R1 586 #define R2 701 int main() { int number; int i; srand(time(0)); ......
openssl——实验一
openssl实践——实验一 20201303张奕博 0. 安装Ubuntu和OpenEuler虚拟机 1. 下载最新的OpenSSL源码(1.1版本) 2. 用自己的8位学号建立一个文件夹,cd 你的学号,用pwd获得绝对路径 3. 参考https://www.cnblogs.com/rocedu ......
实验2
TASK1 //程序作用 :随机生成五个学号 #include<stdio.h> #include<stdlib.h> #include<time.h> #define N 5 #define R1 586 #define R2 701 int main() { int number; int i ......
实验二
实验任务1 task1.c #include<stdio.h> #include<stdlib.h> #include<time.h> #define R2 701 #define N 5 #define R1 586 int main() { int number; int i; srand( t ......
单片机第六次实验课——计数器实验
六、单片机第六次实验课——计数器实验 (1)采用定时器与计数器相结合的方法使P1.1所接的发光二极管亮1秒、灭1秒,周而复始。(查询方式、中断方式) 分析:晶振频率40MHZ,机器周期为(1/40)12=03μs,采用工作方式1最大定时为2^160.3≈20ms。若采用20ms为半周期,20ms22 ......
单片机第八次实验课——循环彩灯控制实验(定时器控制方式)
八、单片机第八次实验课——循环彩灯控制实验(定时器控制方式) (1)用 P1 口作为输出口实现循环彩灯。(至少要有 5 种形式) 汇编: ;可自行拓展,这里只写了五种,另外加闪烁模式需修改模式种数增加模式初值个数,在循环内添加对应处理就好了 ORG 0000H MOV DPTR,#TAB1 MOV ......
单片机第七次实验课——A/D 和 D/A 实验
七、单片机第七次实验课——A/D 和 D/A 实验 (1)完成 A/D 接口设计,采用查询方式和中断方式编写程序。 (2)实现 D/A 接口设计,编写程序输出方波、锯齿波、正弦波,使用示波器观察波形。 实验室里只用做第二个 锯齿波汇编: (此处没设延时,如果设延时则一定不要设太大,不然波形会变形) ......
单片机第四次实验课——外部中断实验
四、单片机第四次实验课——外部中断实验 (1)通过外部中断使 P1 口的开关控制8个发光二极管,开始是P1.0所接的灯亮,以后每中断一次,下一个灯亮,顺序左移,周而复始。 1)汇编 ORG 0000H LJMP MAIN ORG 0003H LJMP LINT0 MAIN: MOV TCON,# ......
单片机第五次实验课——定时器实验
五、单片机第五次实验课——定时器实验 (1)采用定时器控制从 P1.0 输出 1000Hz 音频信号。 ORG 0000H LJMP MAIN ORG 000BH LJMP TINT0 MAIN: MOV TMOD,#00000001B MOV TH0,#0F9H MOV TL0,#7EH SETB ......
单片机第三次实验课——P1 口输入、输出实验
三、单片机第三次实验课——P1 口输入、输出实验 (1)P1 口作输出口,接八只发光二极管,编写程序,使发光二极管循环点亮。(采用软件延时的方法) ORG 0000H MOV A,#00000001B MOV P1,A LCALL DELAY LOOP: RL A MOV P1,A LCALL DE ......