![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_224,w_224)
百练题解
这里是北京大学百练算法题的问题以及解答,这里是以C++作为实现算法编程语言。
Alan先生的代码屋
这是一间奇妙的屋子!
展开
-
百练1002:方便记忆的电话号码(C++实现,北大软微)
百练1002:方便记忆的电话号码1-描述英文字母(除Q和Z外)和电话号码存在着对应关系,如下所示:A,B,C -> 2D,E,F -> 3G,H,I -> 4J,K,L -> 5M,N,O -> 6P,R,S -> 7T,U,V -> 8W,X,Y -> 9标准的电话号码格式是xxx-xxxx,其中x表示0-9中的一个数字。有时为了方便记忆电话号码,我们会将电话号码的数字转变为英文字母,如把263-7422记成America。有时,我们还加上“-”作为分隔原创 2020-11-05 07:11:37 · 953 阅读 · 1 评论 -
百练1001:Exponentiation(乘方)(C++实现,北大软微)
百练1001:Exponentiation(乘方)1-问题描述Problems involving the computation of exact values of very large magnitude and precision are common. For example, the computation of the national debt is a taxing experience for many computer systems.This problem requires原创 2020-11-04 20:02:56 · 897 阅读 · 0 评论 -
百练1000:A+B Problem(C++实现,北大软微)
百练1000:A+B Problem1-问题描述Calculate a + b翻译:计算a+b的数值,并输出2-输入Two integer a,b (0 ≤ a,b ≤ 10)3-输出Output a + b4-样例输入1 25-样例输出3^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^自我分析这题掌握C++基本语法亦可。代码实现#include <iostream>using names原创 2020-11-04 15:27:45 · 338 阅读 · 0 评论