Corgo
Corgo
MModular
Created by Corgo on 9/21/2023 in #questions
Type suffixing?
realized i can just do this
fn f(x: Float32) -> Float32:
return x

fn main():
let mult: Float32 = f(.6)*f(.91)
let acceleration: Float32 = f(0.16277136) / (mult * mult * mult)

print(acceleration)
fn f(x: Float32) -> Float32:
return x

fn main():
let mult: Float32 = f(.6)*f(.91)
let acceleration: Float32 = f(0.16277136) / (mult * mult * mult)

print(acceleration)
11 replies
MModular
Created by Corgo on 9/21/2023 in #questions
Type suffixing?
FloatLiteral() casts it to a 64-bit float, whereas i need them to be 32-bit floats
11 replies
MModular
Created by Corgo on 9/21/2023 in #questions
Type suffixing?
yes, the other two print 0.9999998 which is what i'm looking for
11 replies