- 博客(2)
- 收藏
- 关注
原创 实验5一维数组
A - C语言实验——最值 Description 有一个长度为n的整数序列,其中最大值和最小值不会出现在序列的第一和最后一个位置。 请写一个程序,把序列中的最小值与第一个数交换,最大值与最后一个数交换。输出转换好的序列。 Input 输入包括两行。 第一行为正整数n(1≤n≤10)。 第二行为n个正整数组成的序列。 Output 输出转换好的序列。数据之间用空格隔开。 Sample Input 6 2 3 8 1 4 5 Output 1 3 5 2 4 8 #include<stdio.h>
2020-11-27 15:23:10 1722
原创 实验4for循环
A - A+B for Input-Output Practice (II) Description Your task is to Calculate a + b. Input Your task is to Calculate a + b. Output For each pair of input integers a and b you should output the sum of a and b in one line, and with one line of output for each
2020-11-27 15:22:41 977
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人