Join Todd Perkins for an in-depth discussion in this video Solution: Create two variables, part of Programming for Non-Programmers with iOS 10 and Swift.
- [Instructor] Here is one of multiple solutions…to the challenge.…Going to change to iPhone 7 to make sure…I'm testing on that device.…If you actually leave it on a different device…and hit the run button,…that whole device is going to have to boot up in Simulator,…it's going to add extra time.…Change to iPhone 7, then I'm going to head over…to Main.storyboard and drag out two labels.…I'll scroll up so I can see the top…of my view controller right here,…and then I'm going to filter for a label in the object library.…
I'm going to click and drag one out right here,…I'll stretch it out by expanding the handle,…and then I'm going to copy it…by Option+Dragging it down.…So one of these will be a string,…one of these will be an integer.…Now it's time to connect these to code.…I'm going to hide the document outline…clicking the button right here,…and then I'm going to Option+Click ViewController.swift.…That's going to open it up in the Assistant Editor…on the right side of the Editor.…
To get some more space, I'll hide…
- Installing Xcode
- Creating an Xcode project
- Configuring the iOS Simulator
- Understanding variables
- Connecting visual objects to variables
- Understanding methods
- Connecting a button to a method
- Using conditional statements
- Setting up the user interface (UI)
- Building a complete iOS app
Skill Level Beginner
1. Set Up Your Coding Environment
Create an Xcode project4m 19s
2. Programming Building Blocks: Variables
3. Programming Building Blocks: Methods
4. Programming Building Blocks: Conditional Statements
5. Plan and Prepare the App
6. Build a Full Application
Next steps3m 11s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.