iOS Swift Collections and Control Flow Control Flow With Conditional Statements Working With Logical Operators

Whats the issue with this code: logical operators

How is this wrong? I'm supposed to check to see if n is odd and multiple of 7, then append to array

var results: [Int] = []

for n in 1...100 {
    if n%2=1 && n%7=0 {

Nevermind lol. It was just the one equal sign idk how i didnt see that. Sorry folks.

1 Answer

Clark Reilly
Clark Reilly
6,204 Points

This is already answered.