Computer Programming 12

Welcome to Computer Programming 12 

This fast paced course has been designed to build off of the structure introduced in Programming 11. We will revisit familiar units of study but with an entire new level of depth. For example, in Programming 11, we studied HTML and CSS; in Programming 12 we delve into JavaScript (the behaviour side of web development). Everything in this course is unique but relates to a larger whole. We endevour to keep the units covered in the course practical with the goal of giving you the skills to bring your own creative ideas to life. Practicing, building, reverse engineering, iterations and add on's are all strategies we deploy to help you innovate. Although there is some theory in this course, the guiding principles are practical and useful. I do hope that you enjoy this course and that you have a lot of fun along the way! 

Hand In Box for Programming 12 - Please put your full name on assignments and place in correct folder - YOUR RESPONSIBILITY 

Computer Programming 12 - Block 3 

Computer Programming 12 - Block 4 

Contact Mr. Linburg directly: telinburg@sd43.bc.ca 

(*) Note: You will need to have access to Visual Studio (community edition) to edit some of your JavaScript project assignments. As well, be sure to install the "Live Server" extension to your tool suite!  

Programming 12 - Java App Development Presentation - Block 3

 Wednesday May 24th

Programming 12 - Java App Development Presentation - Block 4 

Wednesday May 24th 

Module # 7 - Emerging Technology Discussion

Take a look at the side tab - you can participate in these reflections OR you can work through Module # 6 - Your choice!

Due: Friday June 23rd, 2023 

Module # 6 - Learn SWIFT - Mobile app developer language  

Have you ever wondered how we go from being programmers to becoming 'app developers' for real. How does one create a (phone) app that can actually be hosted on a 'store'. 

Introduction to Swift and Mobile APP development

Overview of the App development process (Using Swift / X code ...)

Introduction - Getting started learning SWIFT syntax and process

An online 'Swift' compiler / Visual Studio add on's to code with SWIFT  

If you want to develop Apps on a Window or Linux platform then you can use this 'translator' to help with this. We are unable to install this on district equipment due to security issues and the need for a district approval but you can use this on your own personal computer. 

Virtual Box - cross operating system for development platform for Mobile APPs (How to use this platform - video intro)  

OR 

App Developer "LITE" - a simulated App development platform

If you want to work on "App Developer LITE" and work on an app 'mock up' you could try this app developer platform developed by MIT that has many similarities to SCRATCH. Code 'drag and drop' tiles! 

Module # 5 - Independent pathways - Choose one area of Interest! 

If nothing 'grabs you' then you are invited to write me a learning proposal for review and approval. (For example, perhaps you might want to complete some more advanced Python project work instead of these options - look on-line for something of interest - then: write an outline / a rationale for this / and the proposed links and scope of work

Option # 1

Introduction To Arduino

What is an Arduino you ask?  Please read this link for a great description of this multipurpose technology! 

A - Arduino starter kits  

Please complete the following introductory projects using the Introductory Arduino kits

To sign up for an account please go here 

Arduino sign up (You will need an account to be able to create and save scripts using the browser based IDE software) 

B - The Keyestudio "super learning kit" 

See the project list to choose from (we'll try to complete 5-7) - We'll spend approximately a week on these. 

1.Hello World / 2.LED Blinking / 3.PWM / 4.Traffic Light / 5.LED Chase Effect / 6.Button-controlled LED / 7.Active Buzzer / 8.Passive Buzzer / 9.RGB LED / 10.Photo Resistor  / 11.Flame Sensor / 12.LM35 Temperature Sensor / 13.Tilt Switch / 14.IR Remote Control

15.Analog Value Reading / 16.74HC595 / 17.1-digit LED Segment Display / 18.4-digit LED Segment Display / 19.8*8 LED Matrix / 20.1602 LCD / 21.9g Servo Control / 22.Stepper Motor / 23.PIR Motion Sensor / 24.Analog Gas Sensor / 25.ADXL345 Three Axis Acceleration Module / 26.HC-SR04 Ultrasonic Sensor / 27.Joystick Module / 28.5V Relay Module  / 29.DS3231 Clock Module

30.DHT11 Temperature and Humidity Sensor  / 31.Soil Humidity Sensor // 32.RC522 RFID Module

Introduction to working with Programmable circuit boards (Arduino Kits) 

In this next course segment, you will be asked to work on creating a few apps using the Arduino starter kits. 

What is an Arduino you ask?  Please read this link for a great description of this multipurpose technology! 

Please complete the following introductory projects using the Arduino kits

To sign up for an account please go here 

Arduino sign up (You will need an account to be able to create and save scripts using the browser based IDE software) 

Option # 2 - Learn the essentials of C++

Introduction to C++  The "original object orientated" language!

 A great language to know for Engineering and related fields!

All we will have time for in this segment is a brief introduction to the coding fundamentals of C++. We will work off a browser based IDE and compiler for this introduction. 

"This powerful language incorporates features of object-oriented paradigm mixed with the features of C programming language."

Here is a brief history of C++ 

Instructions 

Please take some time to pick and choose some of the lessons from this on line resource. In the section below, I have made some specific suggestions about what you might practice, however I will leave this choice up to you. The problem, going forward, might not be that C++ is particularly hard but perhaps remembering WHICH naming conventions are used for which language! 

Introduction to C ++   approach # 1

My suggestion is to pick and choose a collection of lessons. You should know, for example, how a C++ program is set up, and what are the essential attributes of any C++ project. You also should be versed in functions, classes and variables. Hopefully you will start to see that C++ is just another coding language that has many things in common with other languages such as Java and Python. 

The image below shows the format for entering code into the C++ coding terminal shell. Click on the icon on the far right of the screen. 

Introduction - approach # 2 

Here is another good resource link to help you get started working your skills with this important programming language. 

Part II - Coding project choices using C++ 

Choice A

Please use the following link as a project resource for this segment. You are to download a zip file to use for each of the projects you pursue. Some of the projects to choose from include: 

A casino number game / hangman / snakes and ladders / tic tac toe / banking system project / supermarket billing project...

You can use Visual Studio (with extensions) for most of these C++ projects. Good luck and have fun! 

Choice B

Game making using C++  /

Build an C++ app using Visual Studio (calculator) 

Instructions 

Please access the games and the related C++ code. 

Reference guides for C++ 

On-line reference guide - number one (on-line) - click the category for more specific information 

Option # 3    Introduction to SQL  Back end data base storing and retrieving information 

SQL is a standard language for storing, manipulating and retrieving data in databases.

Tutorial linkCode Academy (work through a collection of practice exercises) - Don't feel any expectation to do them all, pick and choose. You will essentially use this site as a project resource. Now look through the PDF text that gives you a collection of puzzles to solve, while learning SQL at the same time! :) 

A great place to locate 'free' databases from which to conduct database queries.

Exercises and activities related to SQL 

Module # 4 -Introduction to Object Oriented Java (Book II)

Java Textbook # 2 - Please download - 

 Object Oriented Java - download the PDF off this link! ?OOP's data files for exercises (please download this as well!) 

In this final Java course segment, we will be learning about Object Oriented Java OOP's. This is what Java is known for. 

Part I - Introduction (reading / note taking)

Please read through the following links to help you get started! You are asked to make a short summary of key concepts listed below (part A and part B) 

(One page in total from the following links - 'mix and match' - You decide what is important) 

Section A - OOP's - what is it? 

Key OOP's concepts / Another good guide

Here are two graphics that outline general Object Oriented Java principles within the context of a soccer game.

Section B - How is OOP's different 

Why OOP's - how is it different or better than using traditional programming? 

Part II - OPP's Related practice lessons (see attachment section for data files and Java web sites)

Here is the link for the first collection of exercises - 12 lessons in total - Same lessons as the PDF textbook...perhaps this format is easier access (up to you). - we will hopefully do more than these 12 but it depends on how these go...

Technical specifics of creating OOP's applications

1) We do NOT USE AN IDE like Netbeans for Object oriented lessons we use terminal shell.

2) Figure out how to open windows terminal shell x86 to type in commands (see lesson "0" for more info)

3) Add the JDK to the system PATH - should have already been done - but you should check

4) Please do ONE of the study drills from EACH of the 12 lessons.

If you're having problems seeing an output message be sure you have complied first Java C then run the exercise!

Great reference guides

OOPs explained with great examples!

Part III - Make your own app (either OPP's based or based on other Java skills) - May 24th

In the next segment you will harness your newfound skills with OOP's to either create an original application or complete a pre existing project (with your own modifications).

Option 1 - Create your own based on the lessons covered so far (concepts based on lessons 1-17)

In the first option, you could create a calculator that uses the square root function mentioned in one of the lessons. However, our skills are still fairly limited so you could also rewrite an EXISTING exercise with different functions from both book ONE and book TWO. I know this is rather general but it follows a similar theme of reinvention as described in other previous lessons.

Option # 2 - Make a game and / or a specific application using one of the links below as a guide.

If these don't work then try these links

Option # 3 - Game of "Floppy Bird"

A fun game to make for your Java based skills! / Link to a student made game collection (examples - can't speak to ALL their quality however :) ) 

Module # 3    Java Textbook   

last segment of book one and associated app development

In this follow up assignment, you are now tasked with scripting a collection of text based programs using "our coding textbook friend" Learn Java the Hard way (end of book one). They use "netbeans' but you should use Visual Studio. 

Click on this one drive link and download the textbook resource

How to use Visual studio for Java

Part I  Write output programs in Visual Studio (second half of book one)

(*) please do ONE study drill at the end of each of these exercises.- only submit the exercise AFTER you have done the study drill (in other words the MODIFIED one) - add a developer comment to make sure I know WHICH study drill you completed.

# 25 Repeating yourself with the while loop

# 26 A number Guessing game

# 27 Infinite Loops

# 29 Do-While Loops (*) More challenging (More background info on Do-While loops - ) 

The Key difference between While Loops and Do...While loops is...


The do...while loop is similar to while loop. However, the body of do...while loop is executed once before the test expression is checked

This is as opposed to the 'While loop" which... 

Java while loop is used to run a specific code until a certain condition is met. The syntax of the while loop is: 

# 30 Adding values one at a time

# 33 Calling a Function

# 34 Calling Functions to draw a flag (*) note - if you can, draw any flag you wish for this exercise

# 35 Displaying Dice with Functions 

# 36 - Returning a value from a Function (*) More challenging

# 44 Counting with a For Loop

# 47 - Generating and Filtering Values

# 48 - Arrays - Many values in a single Variable

# 49 - Arrays continued


Part II - Making a Diverse range of Apps with Java 

We will now pause and try to find practical uses and application for the Java related skills that we have learned so far. What sort of things can we make with our new found skill set. Take a look at some of these links. Hopefully you might find ONE project you have an interest in making. If not, then you could search for one to your liking. These links have a diverse range of options. Have fun and happy coding!

(*) Some of the above links aren't tutorials per se but rather guides or examples of what your project might look like. 

Module # 2 - Using JavaScript to make your own games - Final Submission Date: Thursday, April 6th, 2023 (NO extensions) - move to the next module when done!

Part I 

Make a guessing game based on the GitHub version - FIVE modifications min.   

Part II 

Option # 1

Create your very own game of 'Hangman' - the classic work guessing game! 

We are now moving on from 'studying' other peoples exceptional coding projects and transitioning to our role as developers. You will use this guide to help you write your own game of 'Hangman'. You are, of course, encouraged to personalize it and change its look and design AFTER you have finished the basic constructions steps. Happy coding! :) At the end of this, we will submit these to peer assessment and get a chance to try everyone else's creations! 

Option # 2 - Create your own rendition of one of these JavaScript gaming classics! 

Take a look at some of these other 'classic' games. Perhaps you might find a project listed below that is of interest to you. If you follow a structured tutorial you are asked to 'personalize' it with 10 specific changes (please add a developer comment at the top of the script with a LIST of the specific changes) I would strongly suggest that you change both the game's behaviour (functions) and its overall appearance (which may include CSS changes) 

Game of Mine sweeper / or You may use one of these as a guide to assist you :) good luck!

JavaScript Game samples - 10 fun ones to make and to play! / Another hangman example (with animation and discussion)

Resource links for this unit 

A basic HTML page you can copy and paste for this activity:  off of this link OR USE Dreamweaver CC.

W3 schools  / JavaScript Fundamentals / complete list of JavaScript programming conventions

MODULE # 1  - Introduction to JavaScript 

JavaScript - one of the world's most popular computer language   

Unit Description

We will be starting this unit by completing some structured introductory tutorials to help you learn the language structures; then we will give you actual working JavaScript made by developers for you to break, modify and then improve. 

Finally, we will invent our own apps based upon the skills of other developers. 

History of JavaScript - an interesting read! 

JavaScript intro 1  / JavaScript intro 2

Section # 1 - JavaScript 'sandbox'

W 3 Schools Introduction to Java script structures 

In our very first introduction we will be using the W 3 for schools site to learn more about the history of JavaScript and to learn how its constructed. Please load the web site and do one or two 'try this' for each segment. Please try to 'break the code' and change it up anyway you see fit....and see what happens? Be sure to read through each of the segments but the threshold for completing exercises here is not very high. Think of this as an 'interactive' intro. 

Please share your insights from THREE of the exercises (you should include some specific script reference). (half a page or more)

Section # 2    JavaScript Practice - Code Academy Intro. 

(*) NOTE: Code academy erects a paywall after section two. The only way around this is to make a new profile and then you should be able to continue on with the rest. Please "screen shot" what you did in part one - you are NOT expected to repeat anything in your 'alternate profile' on the site. 

Sequential Code Academy lessons (free lesson segments - see below) 

 Introduction /  conditionals /  functions /  arrays /  loops /  classes (in the last section) - skip the rest

Please complete this introductory work on JavaScript:   Code Academy site. Please be sure you have completed the lessons as described above. PLEASE complete all the "free" segments. ITERATORS IS NO LONGER REQUIRED FOR CODE ACADEMY. 

Section # 3   JavaScript "Reinvents"   Utilize existing JavaScript projects to improve their function and design

In this segment of JavaScript, we'll be working with CODE PEN and other resources to experiment with novel and creative uses for JavaScript. 

Resource Guides 

(*)Note: please write a specific developer comment in the 'redo' explaining what you actually did to improve the function and design!

Project ONE - Reinvent -JavaScript Clock

(*) Note: One option is to set up your own Code Pen Account and put your edited projects right on that hosted platform and then send me the link to your finished "reinvent". There are other methods we could discuss in class. 

(*) Note: you may want to move your clock code over to either Visual Studio OR Code Pen if you have your own account. If you just edit it off of the W3 school's site there is NO save as function!

Edit in W 3 Schools - 

A JavaScript clock - Please make all your changes right on the W 3 browser. Try to make a minimum of FIVE changes to its look / function / and design. 

Take a look at these 'far out examples' - that you could use for your inspiration and edits! Go crazy and have fun (look below at the video for links to the ACTUAL coding samples!) - Have fun! 

Here is another cool clock example!

 (NOTE: we might use a different platform for this project - stay tuned) 

Additional activity resources

Project TWO -Reinvent - Edit HTML / CSS / JavaScript together 

Take this dreadful looking clock and related message boxes and make TEN changes to the look and behaviour. This could include ONE HTML change / ONE CSS change / and SEVEN JavaScript modifications (i.e. modify a function or change an array)  

Project THREE - Reinvent - Modify the Code Pen version of the game hangman - then remake the game from scratch. 

Experiment and make 10 to 15 changes

A JavaScript game of hangman - Experiment with this JavaScript version of Hangman. Use the reference guides provided. Try to read through the ENTIRE JavaScript, experimenting and changing it as you go. You are only using this for practice, so break it in all ways that you can think of. All your changes will show in the display at the bottom of the page.

Here is a useful 'textbook' help guide that helps walk you through the code for this game! 

Project FOUR - Reinvent one of your own - As you can see Code Pen is like a 'ice cream store of flavours" - find your own game or puzzle or project that is inspiring to you and make 10 changes.  If possible, colour code your changes to make it clear how you've personalized the project!

Here is one such example (word game) or mastermind classic (If you could please send the link to the project "before" as well so that I can compare! / Pickle 'Rick' maze game! -cool colour background gradients!