Victor Choi

  • Home
  • Business
    • Internet
    • Market
    • Stock
  • Parent Category
    • Child Category 1
      • Sub Child Category 1
      • Sub Child Category 2
      • Sub Child Category 3
    • Child Category 2
    • Child Category 3
    • Child Category 4
  • Featured
  • Health
    • Childcare
    • Doctors
  • Home
  • Business
    • Internet
    • Market
    • Stock
  • Downloads
    • Dvd
    • Games
    • Software
      • Office
  • Parent Category
    • Child Category 1
      • Sub Child Category 1
      • Sub Child Category 2
      • Sub Child Category 3
    • Child Category 2
    • Child Category 3
    • Child Category 4
  • Featured
  • Health
    • Childcare
    • Doctors
  • Uncategorized

4/25/2016

Let's learn Set in Swift language

 12:37 AM     Set, Swift     No comments   

Set is different from Array. Array is ordered. By the way Set isn’t. Another different thing is Array can have same elements.

For example,

let ar1 = [1, 1, 1, 1] 

The code above is possible in Array. But you can’t do it in Set.

Set could be similar to Dictionary. Because each element in Set must be unique like Dictionary’s key value. Set conforms Hashable protocol in order to have unique elements.

The different thing between Set and Dictionary is that Set doesn’t have Key value.

Let me organize everything above.

Collection Type Ordered Unique Stores
Array Yes No Elements
Dictionary No Keys Key-value pairs
Set No Elements Elements
  • Share This:  
  •  Facebook
  •  Twitter
  •  Google+
  •  Stumble
  •  Digg
Email ThisBlogThis!Share to XShare to Facebook
Newer Post Older Post Home

0 개의 λŒ“κΈ€:

Post a Comment

Search This Blog

Popular Posts

  • How to put a padding into a UITextField ?
  • Time machine gives error "can't connect to a current time machine backup disk"
  • Keynote Tutorial Text Outline - Make your animation meaningful
  • Keynote Tutorial , Sound is a design,too
  • Keynote Tutorial How to improve your bullets

Blog Archive

  • ►  2020 (2)
    • ►  January (2)
  • ►  2019 (21)
    • ►  December (2)
    • ►  November (6)
    • ►  October (5)
    • ►  September (2)
    • ►  August (3)
    • ►  July (2)
    • ►  June (1)
  • ►  2017 (11)
    • ►  December (2)
    • ►  November (2)
    • ►  July (2)
    • ►  May (1)
    • ►  April (1)
    • ►  March (3)
  • ▼  2016 (48)
    • ►  December (3)
    • ►  November (2)
    • ►  September (1)
    • ►  August (10)
    • ►  July (5)
    • ►  June (7)
    • ►  May (2)
    • ▼  April (18)
      • Why does Google build smart lenses?
      • Will the type 1 diabetes be conquered?
      • The killer app for iPad Pro with Apple Pencil
      • Remove "Desktop Video Firmware Updater" process in...
      • OmniFocus Review Perspective action using Launch C...
      • Not useful to use Drafts with nvAlt on the Mac
      • Let's learn Set in Swift language
      • Launch Center Pro , Custom URL action to open and ...
      • iOS Application States
      • Google's Eric Schmidt uses iPhone6s
      • Fitbit Alta approaches practical users
      • Errors that I met during Apple Watch app development
      • CleanTalk , My choice for wordpress spam filtering
      • Byword for Mac is getting slower!
      • An unkown space between vertical divs
      • Alfred workflow - nvalt actions
      • 10 minutes to understand how to develop Parallax s...
      • A great usage of Launch Center Pro's lc-callback
Powered by Blogger.

Navigation Menu

  • Home
  • About
  • Documentation
  • Contact

Contact Us

Name

Email *

Message *

Copyright © Victor Choi | Powered by Blogger
Design by Hardeep Asrani | Blogger Theme by NewBloggerThemes.com | Distributed By Gooyaabi Templates