- 博客(3)
- 收藏
- 关注
原创 L - Swimmer
L - SwimmerOne day, n of swimmers hold a wonderful competition in a swimming pool.There are n lanes in the swimming pool numbered from 1 to n , and the their lengths are all m meters. Swimmers are also numbered from 1 to n, and swimmer i occpies lane i.
2021-05-29 14:50:14
415
原创 F - String
F - StringAvin has a string. He would like to uniform-randomly select four characters (selecting the same character is allowed) from it. You are asked to calculate the probability of the four characters being ”avin” in order.InputThe first line contains
2021-05-23 13:15:03
108
原创 整数分解
整数分解小明在数学课上,学到了一个整数的性质:任何正整数都可以分解为若干个正整数相加的形式,且分解形式不唯一,其中3=1+2,3=2+1是一种分解形式,给出一个正整数n,按字典序输出所有分解形式输入格式:输入在一行中给出一个整数n输出格式:按字典序输出n的所有分解形式,每种占一行输入样例:在这里给出一组输入。例如:3输出样例:在这里给出相应的输出。例如:1+1+1 1+2代码#include<stdio.h>int a[32];int n,num;voi
2021-05-23 01:52:24
168
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人