Problem 63】的更多相关文章

Problem 63 https://projecteuler.net/problem=63 Powerful digit counts The 5-digit number, 16807=75, is also a fifth power. Similarly, the 9-digit number, 134217728=89, is a ninth power. 五位数16807同时是7的五次方,同样地,九位数134217728是8的九次方. How many n-digit positiv…
这题略水啊 首先观察一下. 10 ^ x次方肯定是x + 1位的 所以底数肯定小于10的 那么我们就枚举1~9为底数 然后枚举幂级数就行了,直至不满足题目中的条件即可break cnt = 0 for i in range(1, 10): e = 1 while True: if len(str(i**e)) != e: break e += 1 cnt += 1 print cnt…
The 5-digit number, 16807=75, is also a fifth power. Similarly, the 9-digit number, 134217728=89, is a ninth power. How many n-digit positive integers exist which are also an nth power? 这种数字满足下面条件: 对于数位为x的数S=k^x 有 10^(x-1)<=k^x<=10^x-1 #include &quo…
UVA127 链接:https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=63 一道非常好的栈的模拟题,训练计划又往后推了一周,因为各种事情,不过自己已经做了修改,另外说一下,今晚寝室那两尊神不在,难得的心情好, 这题其实还是看了别人的代码的,大牛博客:http://blog.csdn.net/hyczms/article/details/380…
CTF--练习平台 例题: 一段Base64 flag格式:flag{xxxxxxxxxxxxx} 附件: base64.txt 1.base64解码:http://base64.xpcha.com/ 2.解码后发现是个8进制的加密 <script> document.write("<textarea cols=55 rows=10>"+ " 填上解码后得到的8进制数 " +"</textarea>"); &l…
系统环境 # cat /etc/redhat-release Red Hat Enterprise Linux release 8.0 (Ootpa) 安装依赖 # yum install -y yum-utils device-mapper-persistent-data lvm2 Last metadata expiration check: 0:33:56 ago on Tue 18 Feb 2020 12:30:53 AM UTC. Dependencies resolved. ====…
$s = curl_init(); curl_setopt($s, CURLOPT_POST, true); curl_setopt($s, CURLOPT_POSTFIELDS, $queryStr); curl_setopt($s, CURLOPT_URL, $url); curl_setopt($s, CURLOPT_TIMEOUT, 1000); curl_setopt($s, CURLOPT_RETURNTRANSFER, 1); $body = curl_exec($s); if($…
root# cmake .. No problem. root# make [ 63%] Linking CXX shared module collisionperceptor.so/usr/bin/ld: /usr/local/lib/libode.a(ode.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC…
Problem A: 2016 Time Limit: 5 Sec  Memory Limit: 128 MB Description  给出正整数 n 和 m,统计满足以下条件的正整数对 (a,b) 的数量: 1. 1≤a≤n,1≤b≤m; 2. a×b 是 2016 的倍数. Input 输入包含不超过 30 组数据. 每组数据包含两个整数 n,m (1≤n,m≤109). Output 对于每组数据,输出一个整数表示满足条件的数量. Sample Input 32 63 2016 2016…
Problem about GCD Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 470    Accepted Submission(s): 77 Problem Description Given integer m. Find multiplication of all 1<=a<=m such gcd(a, m)=1 (cop…