
Advanced Programming Concepts Review and Solutions
Explore day 4 review, Git and Docker pulls, datatype updates, predicates, and well-formed predicates in advanced programming. Discover solutions, examples, and insights for optimizing code efficiency and structure.
Download Presentation

Please find below an Image/Link to download the presentation.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.
You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.
E N D
Presentation Transcript
git pull (and maybe docker pull)
datatype update syntax var oldmap:map<string,int>; newmap == oldmap["a" := 7] var oldseq:seq<bool>; newseq == oldseq[3 := true] datatype Cat(coloring: Coloring, fur: Length) predicate ShaveCat(cat: Cat, cat': Cat) { newcat == oldcat.(fur := Short) }
Well-Formed predicates some people introduced these independently -- hooray! What are they? an "extension of the type" require WF everywhere reduces/centralizes boilerplate easy to prove Typical examples length constraints on sequences indices fit into a sequence length domains of maps