1148 -- 小光棍数
来源:互联网 发布:手游推广联盟源码 编辑:程序博客网 时间:2024/05/15 08:33
小光棍数
Time Limit:1000MS Memory Limit:65536K
Total Submit:205 Accepted:99
Description
最近Topcoder的XD遇到了一个难题,倘若一个数的三次方的后三位是111,他把这样的数称为小光棍数。他已经知道了第一个小光棍数是471,471的三次方是104487111,现在他想知道第m(m<=10000000000)个小光棍数是多少?
Input
有多组测试数据。第一行一个整数n,表示有n组测试数据。接下来的每行有一个整数m。
Output
输出第m个小光棍数。
Sample Input
11
Sample Output
471
Source
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace AK1148 { class Program { static void Main(string[] args) { int n = int.Parse(Console.ReadLine()); while (n-- > 0) { long x = long.Parse(Console.ReadLine()); Console.WriteLine("{0}471", x - 1); } } } }
0 0
- 1148 -- 小光棍数
- akoj-1148-小光棍数
- 小光棍数
- 小光棍数
- 小光棍数
- 小光棍数
- NYOJ_458小光棍数
- 小光棍数
- 小光棍数
- 458 小光棍数
- 小光棍数
- nyoj458小光棍数
- nyist 小光棍数
- 小光棍数
- 小光棍数
- ACM-小光棍数
- nyoj458小光棍数
- 小光棍数
- FontAwesome图标制作(css)
- noip2004 津津的储蓄计划 (模拟)
- HDU1269-迷宫城堡
- 【坑】javascript中让setTimeout方法间隔时间更为精确
- spring mvc + MyBatis + Easyui
- 1148 -- 小光棍数
- UITableView的使用和点击每个cell跳转到其他controller优化
- android 学习笔记 光照传感器的用法
- UIAlertView在其他页面快速显示?
- Ambari2.1安装hdp2.3
- 1149 -- 光棍节的快乐
- ReactiveCocoa-基础
- 面试之jsp、Servlet相关知识——生命周期,区别等
- Hadoop第9周练习—Hive部署测试(含MySql部署)