Let’s build, test, and validate the basics of the data store. In this hands-on coding lab, you’ll build the basic functionality and attributes of the data store in 3 different implementations: procedural, static class, and OOP. You’ll build a full test suite. And you’ll validate that the code complies to the WordPress Coding Standard.
Before we can build the data store, we need to understand what it is we need to build. In this lab, you’ll think through each of the requirements, working to define what makes a store a store, how to interact with it, what functionality is needed, and conceptually how to achieve it, and then what approaches you’ll employ in the series.
Pseudocode helps you to transition from visual mapping, as you did in the last episode, to a textual format. It’s written in a generic non-state specific format. It’s the building block of code before you write your actual code.
In this episode, you will learn about different techniques for visualizing computation. You’ll learn about how to conceptual view your code, do visual mockups and maps, flowcharting, and thought and planning tools. Your key takeaways are: Conceptual view of code Visual mockups and mapping help you see the big elements Flowcharting helps you to map out the individual steps and conditions Thought and planning tools Study Notes How do you visualize the steps to do something? Using visualization, we’re able to map out the process for registering. Now convert this into something useful. Think logically. The flowchart helps you with […]
Your next step is to learn about computational (or programmatic) thought. Your key takeaways are: Computers are stupid Software tells the computer explicitly how to solve a problem Computational thought is the act of expressing how to solve a problem Building software is a thinking profession Study Notes What is computation? Per Merriam-Webster the act or process of computing or calculating something a system of reckoning What is computing? Per Merriam-Webster to find out (something) by using mathematical processes Why mathematical processes? Remember: computers are comprised of circuitry and software. Methodical Logical Step-by-step expression Proof Drive to the solution What […]
In this episode, you will walk through how to express the solution in steps. Remember that the computer requires the exact steps and conditions in order to execute the code. You’ll do various exercises to identify the exact steps. Expressions must be explicit, step-by-step, repeatable, and absolute. Oh, and you get to learn about algorithms too. Your key takeaways are: Software tells the calculator (computer) how to solve the problem The solution is expressed in a language The expression attributes are: Explicit Step-by-step Repeatable Absolute An algorithm is a recipe. It is a set of explicit, step-by-step, repeatable, and absolute […]
Let’s introduce this lab to you. You are going to learn about how to express and visualize problems. Fact Computers are very fast, but they are stupid. Why? Because you have to explicitly tell them what to do. Step-by-step. Never forget this. How does a computer do complex things? Software! Computers do not think and they do not reason. That’s your job. Computers are 1s and 0s – circuitry. You have to learn how to get the computer to do what you need. Software explicitly tells the computer how to solve a problem. The computer runs the program exactly the […]
Let’s talk about scoping, i.e. who can communicate with whom in your program. It defines the rules to define what code can talk with other code. This is a technical discussion which includes how memory is used and allocated.
You need to embrace abstraction in your programming techniques. Abstraction is one of those big scary words. It removes and hides complexity, allows you to build code in a modular, purposeful fashion, and code to only what is needed. Your key takeaways are: Abstraction promotes quality code Skinny, purposeful code Promotes reuse and modularity Hides complexity Improves maintainability Study Notes What is abstraction? Purposeful methodology – everything in your code should have a specific purpose and function. Everything in that code should support only that task. Being purposeful is an earmark of quality coding. Remove or hide complexity – you only […]
Software has an order of execution. This is the program sequence, meaning the order in which your lines of code will be executed. Your key takeaways are: Software executes synchronously unless asynchronous features are used Execution is in order until it encounters a control statement Order of Precedence follows rules from math Study Notes There is an order or sequence to program execution. Lines of Code Execution Types of code execution: Synchronous – current line of code is executed before moving on to the next line Asynchronous – parallel processing Languages execute code in sequential order Branching and iterators can […]