- 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.
推薦閱讀
- Instant Testing with CasperJS
- Java高并發(fā)核心編程(卷2):多線程、鎖、JMM、JUC、高并發(fā)設(shè)計(jì)模式
- Windows系統(tǒng)管理與服務(wù)配置
- Practical Windows Forensics
- Mastering Kali Linux for Web Penetration Testing
- Hands-On Automation Testing with Java for Beginners
- 前端HTML+CSS修煉之道(視頻同步+直播)
- C語(yǔ)言程序設(shè)計(jì)實(shí)驗(yàn)指導(dǎo) (第2版)
- Java編程的邏輯
- NoSQL數(shù)據(jù)庫(kù)原理
- Creating Stunning Dashboards with QlikView
- Android驅(qū)動(dòng)開(kāi)發(fā)權(quán)威指南
- 超簡(jiǎn)單:Photoshop+JavaScript+Python智能修圖與圖像自動(dòng)化處理
- Learning C++ by Creating Games with UE4
- 深度學(xué)習(xí)入門:基于Python的理論與實(shí)現(xiàn)