自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

WhileTrue

古之成大事者,不惟有超世之才,亦必有坚忍不拔之志

  • 博客(8)
  • 资源 (1)
  • 收藏
  • 关注

原创 A. Vasya and Socks

Vasya has n pairs of socks. In the morning of each day Vasya has to put on a pair of socks before he goes to school. When he comes home in the evening, Vasya takes off the used socks and throws them a...

2018-05-20 11:34:09 191

原创 独木舟

n个人,已知每个人体重。独木舟承重固定,每只独木舟最多坐两个人,可以坐一个人或者两个人。显然要求总重量不超过独木舟承重,假设每个人体重也不超过独木舟承重,问最少需要几只独木舟? Input 第一行包含两个正整数n (0<n<=10000)和m (0<m<=2000000000),表示人数和独木舟的承重。接下来n行,每行一个正整数,表示每...

2018-05-20 10:34:58 843

原创 大数相加(分正负数)

给出2个大整数A,B,计算A+B的结果。 Input 第1行:大数A第2行:大数B(A,B的长度 <= 10000 需注意:A B有可能为负数) Output 输出A + B Sample Input 68932147586468711654886 ...

2018-05-16 22:50:26 892

转载 C语言实现大数相加相减和相乘

首先是字符串翻转函数,大数相加、相减和相乘中都用到了这个函数[cpp] view plain copy /* ** 字符串翻转 */  void Reverse(char *str, int n)  {      int i;        for (i = 0; i < n / 2; i++)      {          char tmp;          tmp = str[i];...

2018-05-15 20:58:39 1688 1

原创 Least Common Multiple

Problem Description The least common multiple (LCM) of a set of positive integers is the smallest positive integer which is divisible by all the numbers in the set. For example, the LCM of 5, 7 and 15...

2018-05-10 16:19:50 94

转载 Big Number

Problem Description In many applications very large integers numbers are required. Some of these applications are using keys for secure transmission of data, encryption, etc. In this problem you are g...

2018-05-10 13:11:22 72

原创 NYOJ 阶乘因式分解(二)

阶乘因式分解(二) 时间限制:3000 ms  |  内存限制:65535 KB 难度:3 描述 给定两个数n,m,其中m是一个素数。 将n(0<=n<=2^31)的阶乘分解质因数,求其中有多少个m。 注:^为求幂符号。  输入第一行是一个整数s(0<s<=100),表示测试数据的组数随后...

2018-05-05 21:29:30 134

转载 三角形顺时针和逆时针的判定

利用矢量叉积判断是逆时针还是顺时针。    设A(x1,y1),B(x2,y2),C(x3,y3),则三角形两边的矢量分别是:    AB=(x2-x1,y2-y1), AC=(x3-x1,y3-y1)    则AB和AC的叉积为:(2*2的行列式)    |x2-x1, y2-y1|    |x3-x1, y3-y1|    值为:(x2-x1)*(y3-y1) - (y2-y1)*(x3-x1...

2018-05-05 20:08:13 1697

用js实现的飞机大战的代码以及素材分享给大家

用js实现的飞机大战的代码以及素材分享给大家

2020-04-24

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除