File tree Expand file tree Collapse file tree 7 files changed +7
-8
lines changed
Expand file tree Collapse file tree 7 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 11fn main ( ) {
2- // TODO: Fix the code to print "Hello world!".
3- printline ! ( "Hello world!" ) ;
2+ println ! ( "Hello world!" ) ;
43}
Original file line number Diff line number Diff line change 11fn main ( ) {
22 // TODO: Add the missing keyword.
3- x = 5 ;
3+ let x = 5 ;
44
55 println ! ( "x has the value {x}" ) ;
66}
Original file line number Diff line number Diff line change 11fn main ( ) {
22 // TODO: Change the line below to fix the compiler error.
3- let x;
3+ let x = 11 ;
44
55 if x == 10 {
66 println ! ( "x is ten!" ) ;
Original file line number Diff line number Diff line change 11fn main ( ) {
22 // TODO: Change the line below to fix the compiler error.
3- let x: i32 ;
3+ let x: i32 = 3 ;
44
55 println ! ( "Number {x}" ) ;
66}
Original file line number Diff line number Diff line change 11// TODO: Fix the compiler error.
22fn main ( ) {
3- let x = 3 ;
3+ let mut x = 3 ;
44 println ! ( "Number {x}" ) ;
55
66 x = 5 ; // Don't change this line
Original file line number Diff line number Diff line change @@ -3,6 +3,6 @@ fn main() {
33 println ! ( "Spell a number: {number}" ) ;
44
55 // TODO: Fix the compiler error by changing the line below without renaming the variable.
6- number = 3 ;
6+ let number = 3 ;
77 println ! ( "Number plus two is: {}" , number + 2 ) ;
88}
Original file line number Diff line number Diff line change 11// TODO: Change the line below to fix the compiler error.
2- const NUMBER = 3 ;
2+ const NUMBER : u32 = 3 ;
33
44fn main ( ) {
55 println ! ( "Number: {NUMBER}" ) ;
You can’t perform that action at this time.
0 commit comments