Search
 
SCRIPT & CODE EXAMPLE
 

SWIFT

Tuple: Nested Tuple and List

# list and tuple can contain mixed datatypes, and nested in anyway

my_list =  [3, "4", [11, "12"], ("a", 2), 5]
my_tuple = (3, "4", [11, "12"], ("a", 2), 5)

print(my_list)
# [3, '4', [11, '12'], ('a', 2), 5]

print(my_tuple)
# (3, '4', [11, '12'], ('a', 2), 5)
Comment

PREVIOUS NEXT
Code Example
Swift :: swiftui orientation failed after change orientation popup 
Swift :: Swift Conforming Multiple Protocols 
Swift :: octobercms add extra slash to css url 
Swift :: Struct Instances Swift 
Swift :: where to save audio asset swift 
Swift :: Swap/Change Rootviewcontroller with Animation ios/swift 
Swift :: Swift Nil-coalescing operator 
Swift :: swift await async 
Swift :: cellwidget to setvalue 
Ruby :: validates length rails 
Ruby :: rails api only with postgress and rspec 
Ruby :: find records created in a particular month rails 
Ruby :: dotenv-rails comments 
Ruby :: How can I rename a database column in a Ruby on Rails migration? 
Ruby :: ruby delete folder recursively 
Ruby :: ruby loop from the last array item 
Ruby :: ruby 2 decimal 
Ruby :: ruby string to int 
Ruby :: remove gem rails 
Ruby :: rails where regex 
Ruby :: singleton class in ruby 
Ruby :: save to csv ruby 
Ruby :: rails generate controller no respec 
Ruby :: rails model naming convention 
Ruby :: ruby array shift 
Ruby :: how to run ruby classes 
Ruby :: rails subdomain 
Ruby :: get single hash key ruby 
Ruby :: * 16**index position in ruby 
Ruby :: how to require all .rb files in rails 
ADD CONTENT
Topic
Content
Source link
Name
3+5 =