- Perl 6 Deep Dive
- Andrew Shitov
- 46字
- 2021-07-03 00:05:50
Checking whether the number is prime
The is-prime method returns a Boolean value, telling us whether the number is a prime number or not, as shown here:
say 10.is-prime; # False
say 11.is-prime; # True
Executing the is-prime method on big numbers may be slow.
推薦閱讀
- Learning Cython Programming
- Maven Build Customization
- 零基礎(chǔ)學(xué)Python數(shù)據(jù)分析(升級版)
- 小程序開發(fā)原理與實(shí)戰(zhàn)
- Python面向?qū)ο缶幊蹋簶?gòu)建游戲和GUI
- Android系統(tǒng)原理及開發(fā)要點(diǎn)詳解
- 深入淺出React和Redux
- Microsoft Dynamics AX 2012 R3 Financial Management
- Node學(xué)習(xí)指南(第2版)
- Python機(jī)器學(xué)習(xí)與量化投資
- 體驗(yàn)之道:從需求到實(shí)踐的用戶體驗(yàn)實(shí)戰(zhàn)
- Apache Solr for Indexing Data
- Effective C++:改善程序與設(shè)計的55個具體做法(第三版)中文版(雙色)
- HTML5程序開發(fā)范例寶典
- Selenium Essentials