mirror of
https://github.com/Ed94/LangStudies.git
synced 2025-01-22 04:23:45 -08:00
BAPFS Lecture 13
This commit is contained in:
parent
948974857a
commit
6832deb5ad
32
Builds/Tests/11.Iteration.uf
Normal file
32
Builds/Tests/11.Iteration.uf
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
// While Statement
|
||||||
|
while ( x > 10 )
|
||||||
|
{
|
||||||
|
x -= 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Do-While Statement
|
||||||
|
do
|
||||||
|
{
|
||||||
|
y -= 1;
|
||||||
|
}
|
||||||
|
while ( y > 10 );
|
||||||
|
|
||||||
|
// For Statement
|
||||||
|
for (let index = 0; index < 10; index += 1)
|
||||||
|
{
|
||||||
|
x += index;
|
||||||
|
}
|
||||||
|
|
||||||
|
// For Statement (Optionals)
|
||||||
|
for (;;)
|
||||||
|
{}
|
||||||
|
|
||||||
|
for (let index = 0, z = 12; index < 10; index += 1)
|
||||||
|
{
|
||||||
|
x += index;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (index = 0; index < 10; index += 1)
|
||||||
|
{
|
||||||
|
x += index;
|
||||||
|
}
|
1056
Editor/Lectures/Lecture.13.gd
Normal file
1056
Editor/Lectures/Lecture.13.gd
Normal file
File diff suppressed because it is too large
Load Diff
@ -44,8 +44,8 @@ const TokenType = \
|
|||||||
const TokenSpec = \
|
const TokenSpec = \
|
||||||
{
|
{
|
||||||
# Comments
|
# Comments
|
||||||
TokenType.CommentLine : "^\/\/.*",
|
TokenType.CommentLine : "^\\/\\/.*",
|
||||||
TokenType.CommentMultiLine : "^\/\\*[\\s\\S]*?\\*\\/",
|
TokenType.CommentMultiLine : "^\\/\\*[\\s\\S]*?\\*\\/",
|
||||||
|
|
||||||
# Formatting
|
# Formatting
|
||||||
TokenType.Whitespace : "^\\s+",
|
TokenType.Whitespace : "^\\s+",
|
||||||
|
@ -18,7 +18,7 @@ config/icon="res://Assets/Branding/RDP_Class_cover_small.png"
|
|||||||
[autoload]
|
[autoload]
|
||||||
|
|
||||||
GScene="*res://Lectures/Lecture.tscn"
|
GScene="*res://Lectures/Lecture.tscn"
|
||||||
GScript="*res://Lectures/Lecture.12.gd"
|
GScript="*res://Lectures/Lecture.13.gd"
|
||||||
|
|
||||||
[gui]
|
[gui]
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user