iOS Swift Basics Swift Operators Working With Operators

malcolm henry
malcolm henry
467 Points

Doesn't show complier errors but won't let me through

anyway to continue the lesson

operators.swift
let value = 200
let divisor = 5
let isPerfectMultiple = 0


let someOperation = 20 + 400 % 10 / 2 - 15
let anotherOperation = 52 * 27 % 200 / 2 + 5

// Task 1 - Enter your code below
let result = value % divisor

// Task 2 - Enter your code below
isPerfectMultiple == result

1 Answer

Cristian Sedano
Cristian Sedano
iOS Development with Swift Techdegree Graduate 11,079 Points

// Task 1 - Enter your code below

let result = value % divisor

// Task 2 - Enter your code below

let isPerfectMultiple = (result == 0)

malcolm henry
malcolm henry
467 Points

ended up working with a Bool -- i had no idea to even use a Bool or to be specific.