Programming in Lua, Fourth Edition Roberto Ierusalimschy Copyright © 2016, 2003 Roberto Ierusalimschy Feisty Duck Digital Book Distribution www.feistyduck.com Licensed for the exclusive use of: Eric Taylor <jdslkgjf.iapgjflksfg@yandex.com> Contents About the Book ................................................................................................................. ix I. The Basics ...................................................................................................................... 1 1. Getting Started ........................................................................................................ 4 Chunks .............................................................................................................. 4 Some Lexical Conventions ................................................................................... 6 Global Variables ................................................................................................. 7 Types and Values ................................................................................................ 7 Nil ............................................................................................................ 8 Booleans .................................................................................................... 8 The Stand-Alone Interpreter .................................................................................. 9 2. Interlude: The Eight-Queen Puzzle ............................................................................ 12 3. Numbers ............................................................................................................... 15 Numerals .......................................................................................................... 15 Arithmetic Operators .......................................................................................... 16 Relational Operators .......................................................................................... 17 The Mathematical Library ................................................................................... 18 Random-number generator .......................................................................... 18 Rounding functions .................................................................................... 18 Representation Limits ......................................................................................... 19 Conversions ...................................................................................................... 21 Precedence ....................................................................................................... 22 Lua Before Integers ........................................................................................... 22 4. Strings ................................................................................................................. 24 Literal strings .................................................................................................... 24 Long strings ..................................................................................................... 25 Coercions ......................................................................................................... 26 The String Library ............................................................................................. 27 Unicode ........................................................................................................... 29 5. Tables .................................................................................................................. 33 Table Indices .................................................................................................... 33 Table Constructors ............................................................................................. 35 Arrays, Lists, and Sequences ............................................................................... 36 Table Traversal ................................................................................................. 38 Safe Navigation ................................................................................................. 38 The Table Library ............................................................................................. 39 6. Functions .............................................................................................................. 42

pdf文档 Programming_in_Lua,_4th_ed._(2017)_

计算机 > 脚本语言 > 脚本语言-1 > 文档预览
308 页 0 下载 756 浏览 0 评论 0 收藏 3.0分
温馨提示:如果当前文档出现乱码或未能正常浏览,请先下载原文档进行浏览。
Programming_in_Lua,_4th_ed._(2017)_ 第 1 页 Programming_in_Lua,_4th_ed._(2017)_ 第 2 页 Programming_in_Lua,_4th_ed._(2017)_ 第 3 页 Programming_in_Lua,_4th_ed._(2017)_ 第 4 页 Programming_in_Lua,_4th_ed._(2017)_ 第 5 页
下载文档到电脑,方便使用
还有 303 页可预览,继续阅读
本文档由 user2022-02-09 07:07:32上传分享
给文档打分
您好可以输入 255 个字符
DocHub文库的中文名是什么?( 答案:多哈 )
评论列表
  • 暂时还没有评论,期待您的金玉良言