How to compare below 2 strings? let str1 = "string1" let str2 = "string2”
Correct Answer: if str1 == str2
Explanation:
Note: This Question is unanswered, help us to find answer for this one
Swift Skill Assessment
Your Skill Level: Poor
Retake Quizzes to improve it
More Swift MCQ Questions
The structure of a value or ____ value?
Output when following statement is executed? import UIKit let filename:String =
Output? import UIKit var array:[String] = ['string1', 'string2']; print('array list has (array.count) items.');
How to get local IP address in swift?
Following code which is super class? class X: Y { let str:String let val:Int? … init() { … } deinit(){ … } }
If a class has a superclass and conforms to multiple protocols, what is the correct order to list their names in the initial definition of the Subclass?
Which of these operators is used to check whether or not two instances are identical?
Which of the following could be used to loop through the range of numbers 5-12 including 12?
With which keyword can you declare a constant in Swift?
To declare a function in Swift you would use what keyword?