數字運算,判斷一個數是否接近素數
A Niven number is a number such that the sum of its digits divides itself. For example, 111 is a Niven number because the sum of its digits is 3, which divides 111. We can also specify a number in another base b, and a number in base b is a Niven number if the sum of its digits divides its value.
Given b (2 <= b <= 10) and a number in base b, determine whether it is a Niven number or not.
Input
Each line of input contains the base b, followed by a string of digits representing a positive integer in that base. There are no leading zeroes. The input is terminated by a line consisting of 0 alone.
Output
For each case, print "yes" on a line if the given number is a Niven number, and "no" otherwise.
Sample Input
10 111
2 110
10 123
6 1000
8 2314
0
Sample Output
yes
yes
no
yes
no
Automate Oracle—and save your time for more important tasks! This is the Oracle automation reference every working Oracle DBA needs...concise, straightforward, and incredibly easy to use. Discover proven solutions for automating installation, database creation, management, monitoring, tuning, backup/recovery,
LemonSMS is a component developed in Java that provides a turnkey solution for application developers to incorporate into their Java applications the functionality of sending and processing of incoming SMS messages.
LemonSMS acts as a middleware between a Java application and a GSM Modem or Data enabled phone. Because LemonSMS only provides an interface to the added SMS functionality, your application still handles access to data and business logic tier. With the easy-to-use LemonSMS API, developers can easily utilize SMS functionalities provided by LemonSMS.
"poco" (Spanish & Italian for "little") OLAP provides a web-based, crosstab reporting tool for your datawarehouse. While it s not an OLAP server or full fledged data mining solution, pocOLAP makes your data easy to use and understand ... for free!
這是寫給作為軟件工程項目經理的書,原書的書評是:
"If you re looking for solid, easy-to-follow advice on estimation, requirements gathering, managing change, and more, you can stop now: this is the book for you."
--Scott Berkun, Author of The Art of Project Management