feat: add floats
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
[code]
|
||||
fn test_exponents() -> f64 {
|
||||
let a: f64 = 1e3;
|
||||
let b: f64 = 2.5e-1;
|
||||
return a * b; // 1000.0 * 0.25 = 250.0
|
||||
}
|
||||
|
||||
[harness]
|
||||
extern double test_exponents();
|
||||
|
||||
int main() {
|
||||
if (test_exponents() == 250.0) return 0;
|
||||
return 1;
|
||||
}
|
||||
|
||||
[expected_return_code]
|
||||
0
|
||||
Reference in New Issue
Block a user