COMP 1601 2021W Tutorial 1 Solutions 1. Change line 26 to be let Cs = String(format: "%.2f", C) 2. Add these lines between lines 27 and 28 let Ks = String(format: "%.2f", C + 273.15) Text("\(Fs) is \(Ks) Kelvin") 3. The most straightforward solution is to make an HStack and separate each word into a separate Text view, adding a .bold() to the end of certain words; however, a better solution is to combine words with the + operator, e.g. Text("\(Fs)").bold() + Text(" is ") + Text("\(Cs)").bold() + Text(" Celsius") 4. You just need to duplicate the code from the temperature converter @State private var milesS = "" // at the top of the view struct ... TextField("Enter Miles", text: $milesS) if let miles = Double(milesS) { let km = miles * 1.609344 let kmS = String(format: "%.2f", km) Text("\(milesS)").bold() + Text(" miles is ") + Text("\(kmS)").bold() + Text(" kilometers") } else { Text("Enter a distance please.") } 5. keywords: struct, private, var, if, let, else, some explicit types: ContentView (declaration), View implicit types: string (Fs, Cs), double (F, C) 6. some is a bit weird, what did you find mysterious?