- Perl 6 Deep Dive
- Andrew Shitov
- 81字
- 2021-07-03 00:05:50
Converting to a character using the chr method
Integer values can be converted to the corresponding character. The correspondence is defined by the Unicode codepoint.
In the case of values below 256, it coincides with the ASCII table. Considering the following code snippet:
say 65.chr; # prints A
Higher values produce characters from the Unicode tables, as shown here:
say 8594.chr; # →
The same result can be obtained using the hexadecimal representation, as shown here:
say 0x2192.chr; # →
推薦閱讀
- PHP動態網站程序設計
- R語言數據可視化實戰
- HTML5+CSS3網站設計教程
- Learning Salesforce Einstein
- 硅谷Python工程師面試指南:數據結構、算法與系統設計
- 編程菜鳥學Python數據分析
- C專家編程
- Instant Apache Camel Messaging System
- .NET 4.0面向對象編程漫談:應用篇
- OpenCV 3.0 Computer Vision with Java
- 3ds Max 2018從入門到精通
- Python繪圖指南:分形與數據可視化(全彩)
- Java EE框架開發技術與案例教程
- Microsoft Hyper-V PowerShell Automation
- ReactJS Blueprints