<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://homeostasis.scs.carleton.ca/wiki/index.php?action=history&amp;feed=atom&amp;title=Mobile_App_Development_2021W_Lecture_13</id>
	<title>Mobile App Development 2021W Lecture 13 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://homeostasis.scs.carleton.ca/wiki/index.php?action=history&amp;feed=atom&amp;title=Mobile_App_Development_2021W_Lecture_13"/>
	<link rel="alternate" type="text/html" href="https://homeostasis.scs.carleton.ca/wiki/index.php?title=Mobile_App_Development_2021W_Lecture_13&amp;action=history"/>
	<updated>2026-04-26T12:47:32Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>https://homeostasis.scs.carleton.ca/wiki/index.php?title=Mobile_App_Development_2021W_Lecture_13&amp;diff=22989&amp;oldid=prev</id>
		<title>Soma: /* Video */</title>
		<link rel="alternate" type="text/html" href="https://homeostasis.scs.carleton.ca/wiki/index.php?title=Mobile_App_Development_2021W_Lecture_13&amp;diff=22989&amp;oldid=prev"/>
		<updated>2021-03-01T18:29:23Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Video&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 18:29, 1 March 2021&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Video==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Video==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Video from the lecture given on March 1, 2021 &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;will be &lt;/del&gt;available &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;shortly&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Video from the lecture given on March 1, 2021 &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[https://homeostasis.scs.carleton.ca/~soma/mad-2021w/lectures/comp1601-2021w-lec13-20210301.m4v is now &lt;/ins&gt;available&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;]&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Notes==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;==Notes==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Soma</name></author>
	</entry>
	<entry>
		<id>https://homeostasis.scs.carleton.ca/wiki/index.php?title=Mobile_App_Development_2021W_Lecture_13&amp;diff=22988&amp;oldid=prev</id>
		<title>Soma: Created page with &quot;==Video==  Video from the lecture given on March 1, 2021 will be available shortly.  ==Notes==  &lt;pre&gt; Midterm Review -------------- * assignment 2 solutions * answer questions...&quot;</title>
		<link rel="alternate" type="text/html" href="https://homeostasis.scs.carleton.ca/wiki/index.php?title=Mobile_App_Development_2021W_Lecture_13&amp;diff=22988&amp;oldid=prev"/>
		<updated>2021-03-01T18:25:03Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;==Video==  Video from the lecture given on March 1, 2021 will be available shortly.  ==Notes==  &amp;lt;pre&amp;gt; Midterm Review -------------- * assignment 2 solutions * answer questions...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Video==&lt;br /&gt;
&lt;br /&gt;
Video from the lecture given on March 1, 2021 will be available shortly.&lt;br /&gt;
&lt;br /&gt;
==Notes==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Midterm Review&lt;br /&gt;
--------------&lt;br /&gt;
* assignment 2 solutions&lt;br /&gt;
* answer questions&lt;br /&gt;
* go through assignments/tutorials, extract key concepts&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Key concepts&lt;br /&gt;
 - optional types: if let, !, ??&lt;br /&gt;
 - event handlers in SwiftUI for gestures, taps&lt;br /&gt;
    - onChanged vs onEnded&lt;br /&gt;
 - ForEach in views&lt;br /&gt;
   - to make multiple buttons, etc based on a data structure&lt;br /&gt;
 - forEach in regular functions&lt;br /&gt;
   - how like and unlike for loops&lt;br /&gt;
 - positions for SwiftUI images, other objects&lt;br /&gt;
    - being able to change them directly, rather than having auto&lt;br /&gt;
      positioning/layout&lt;br /&gt;
 - @State and @Binding in views, how they connect views&lt;br /&gt;
 - state in swiftui, how it interacts with view refreshes&lt;br /&gt;
   - events update state&lt;br /&gt;
   - changes in state cause views to be redrawn automatically&lt;br /&gt;
   - should be able to do some basic problem solving with state &amp;amp; bindings&lt;br /&gt;
     - understand what $ is used for in swiftui&lt;br /&gt;
 - splitting apart views using @State &amp;amp; @Binding&lt;br /&gt;
 - + operator in views, HStack, VStack, ZStack&lt;br /&gt;
   - ways to combine views into one view&lt;br /&gt;
 - Menu views&lt;br /&gt;
 - functions &amp;amp; closures in swift&lt;br /&gt;
   - how arguments are specified&lt;br /&gt;
   - named vs unnamed&lt;br /&gt;
   - return values&lt;br /&gt;
 - dictionary, arrays in swift&lt;br /&gt;
 - TextField vs. Text&lt;br /&gt;
   - input and output on screen&lt;br /&gt;
   - bold, italic text&lt;br /&gt;
 - Image views&lt;br /&gt;
   - using assets included in app&lt;br /&gt;
 - for, while loops in swift&lt;br /&gt;
   - range specifications with for&lt;br /&gt;
 - implicit types&lt;br /&gt;
   - when you do and don&amp;#039;t have to specify a type&lt;br /&gt;
     (basics)&lt;br /&gt;
   - the idea is to make code clear without being verbose&lt;br /&gt;
 - var vs let in swift&lt;br /&gt;
   - variable vs constant values&lt;br /&gt;
 - struct vs class&lt;br /&gt;
   - value vs reference types&lt;br /&gt;
 - string interpolation&lt;br /&gt;
   - how to generate a string that includes values in in from variables&lt;br /&gt;
      - put a number in a string&lt;br /&gt;
&lt;br /&gt;
On the midterm&lt;br /&gt;
 - more reading code than writing code&lt;br /&gt;
   - written code will be very short&lt;br /&gt;
 - short answer about specific problems and more general concepts&lt;br /&gt;
   - general follows the specific&lt;br /&gt;
   &lt;br /&gt;
What is a foreach-type loop?&lt;br /&gt;
 - give it an array-ish thing (iterable) plus a closure which takes one argument&lt;br /&gt;
    - closure is called for each element of array&lt;br /&gt;
&lt;br /&gt;
ForEach in SwiftUI is a weird beast&lt;br /&gt;
 - like everything in SwiftUI&lt;br /&gt;
&lt;br /&gt;
In swift, like most strongly-typed languages, symbols have types&lt;br /&gt;
  - types on a symbol don&amp;#039;t change in a scope&lt;br /&gt;
    - but you can redefine variables in different scopes, shadowing the old&lt;br /&gt;
      definition&lt;br /&gt;
    - i in function A and in function B aren&amp;#039;t necessarily the same time,&lt;br /&gt;
      could be a Double in one, int in another&lt;br /&gt;
  - in traditional strongly-typed languages, every symbol had to&lt;br /&gt;
    have an explicit type&lt;br /&gt;
  - in Swift and Kotlin, types don&amp;#039;t have to be specified if they are&lt;br /&gt;
    otherwise clear, e.g., you assign a value of a given type&lt;br /&gt;
&lt;br /&gt;
 - if the value of a symbol can change, it is a &amp;quot;variable&amp;quot;,&lt;br /&gt;
   if it can&amp;#039;t, then it is a &amp;quot;constant&amp;quot;&lt;br /&gt;
     - var vs let in swift&lt;br /&gt;
&lt;br /&gt;
Separate issue is value types vs reference types&lt;br /&gt;
 - this is about what assignment does, A = B&lt;br /&gt;
 - with a value type, A = B makes a copy&lt;br /&gt;
 - with a reference type, A = B means B refers to the same thing A did&lt;br /&gt;
&lt;br /&gt;
Swift is strongly typed, but it is also implicitly typed&lt;br /&gt;
 - so you get the brevity of loosly/dynamically typed languages like&lt;br /&gt;
   Python, JavaScript in that you don&amp;#039;t have to say the type of everything&lt;br /&gt;
 - but you still have the compile-time checking of Java etc&lt;br /&gt;
&lt;br /&gt;
In fact, with optional types, the compile time checking is stricter in&lt;br /&gt;
Swift than Java&lt;br /&gt;
 - can&amp;#039;t &amp;quot;accidentally&amp;quot; do things with a null/nil value&lt;br /&gt;
&lt;br /&gt;
Strongly typed&lt;br /&gt;
 - the compiler knows the types of everything at compile time&lt;br /&gt;
Loosly typed/dynamically typed&lt;br /&gt;
 - compiler doesn&amp;#039;t know all types at compile time, so must be checked at runtime&lt;br /&gt;
&lt;br /&gt;
What is a view?&lt;br /&gt;
 - struct with a body that is a view&lt;br /&gt;
&lt;br /&gt;
Please answer in complete sentences where you can&lt;br /&gt;
 - it is easier to understand and grade, hence better for getting points&lt;br /&gt;
&lt;br /&gt;
But we won&amp;#039;t automatically take points off for bullet points&lt;br /&gt;
&lt;br /&gt;
Midterm is DURING CLASS ON WEDNESDAY&lt;br /&gt;
&lt;br /&gt;
Midterm is open book, open note, open internet&lt;br /&gt;
 - NO COLLABORATION&lt;br /&gt;
 - remember, I&amp;#039;m doing randomized/selected interviews,&lt;br /&gt;
   so misrepresenting what you know is a bad idea&lt;br /&gt;
 - go ahead and use Xcode&lt;br /&gt;
 - I suggest answering everything you can first without using outside&lt;br /&gt;
  resources, THEN go back and use online resources/Xcode to refine answers&lt;br /&gt;
    - outside resources can take up a lot of time, easy to get&lt;br /&gt;
      sucked into figuring out one thing and ignoring the rest of&lt;br /&gt;
      the test&lt;br /&gt;
 - &amp;quot;open book&amp;quot; isn&amp;#039;t so helpful in practice&lt;br /&gt;
&lt;br /&gt;
You have 80 minutes&lt;br /&gt;
 - not sure about # questions yet&lt;br /&gt;
 - I have a draft exam, but I&amp;#039;m still adjusting it&lt;br /&gt;
&lt;br /&gt;
PMC accomodations&lt;br /&gt;
 - go ahead and take your extra time&lt;br /&gt;
 - just send me an email saying that you are&lt;br /&gt;
   - I have the requests&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Midterm will be posted to cuLearn, will submit as a standard &amp;quot;assignment&amp;quot;&lt;br /&gt;
 - not using the cuLearn exam mechanisms&lt;br /&gt;
 - you just edit and submit a textfile template, same as everything else&lt;br /&gt;
 - exam itself will be a PDF&lt;br /&gt;
   - so you can print if you like&lt;br /&gt;
 - exam will become available at 11:35 AM on Wednesday, should&lt;br /&gt;
   be submitted by 12:55 PM&lt;br /&gt;
   - will make minor allowances for technical glitches&lt;br /&gt;
&lt;br /&gt;
Don&amp;#039;t be in zoom by default&lt;br /&gt;
 - msg me on Teams if you have questions, or jump on zoom&lt;br /&gt;
 - we can talk via zoom or teams if I can&amp;#039;t respond via messaging quickly&lt;br /&gt;
   or you can&amp;#039;t ask quickly&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
forEach&lt;br /&gt;
 - method of an array&lt;br /&gt;
&lt;br /&gt;
animals is an array&lt;br /&gt;
&lt;br /&gt;
animals.forEach(closure/function that takes one arg)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Soma</name></author>
	</entry>
</feed>