摘要:
Given N rational numbers in the form "numerator/denominator", you are supposed to calculate their sum.Input Specification:Each input file contains one... 阅读全文
摘要:
“答案正确”是自动判题系统给出的最令人欢喜的回复。本题属于PAT的“答案正确”大派送 —— 只要读入的字符串满足下列条件,系统就输出“答案正确”,否则输出“答案错误”。得到“答案正确”的条件是:1. 字符串中必须仅有P, A, T这三种字符,不可以包含其它字符;2. 任意形如 xPATx 的字符串都... 阅读全文
摘要:
让我们定义 dn为:dn= pn+1- pn,其中 pi是第i个素数。显然有 d1=1 且对于n>1有 dn是偶数。“素数对猜想”认为“存在无穷多对相邻且差为2的素数”。现给定任意正整数N ( 2 #include 3 #include 4 #include 5 #include 6 #in... 阅读全文
摘要:
时间限制400 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueAreversible primein any number system is a prime whose "reverse" in that number system is al... 阅读全文