Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SWIFT

swift remove value dictionary

var someDict:[Int:String] = [1:"One", 2:"Two", 3:"Three"]
var removedValue = someDict.removeValue(forKey: 2)

print( "Value of key = 1 is (someDict[1])" )
print( "Value of key = 2 is (someDict[2])" )
print( "Value of key = 3 is (someDict[3])" )
 
PREVIOUS NEXT
Tagged: #swift #remove #dictionary
ADD COMMENT
Topic
Name
7+9 =