mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-23 09:41:36 +00:00
Fixed almost pi
22/7ths is closer to pi than 11/7ths. Almost twice as close!
This commit is contained in:
parent
df0cd1395d
commit
6a6673b154
@ -91,7 +91,7 @@ var intFromReal = myReal : int;
|
||||
var intFromReal2: int = myReal : int;
|
||||
|
||||
// consts are constants, they cannot be changed after set in runtime
|
||||
const almostPi: real = 11.0/7.0;
|
||||
const almostPi: real = 22.0/7.0;
|
||||
// params are constants whose value must be known statically at compile time
|
||||
// Like consts, they cannot be changed during runtime
|
||||
param compileTimeConst: int = 16;
|
||||
|
Loading…
Reference in New Issue
Block a user