Warning: The magic method Slickr_Flickr_Plugin::__wakeup() must have public visibility in /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php on line 152

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/feed-rss2.php on line 8
davidg2897’s Articles at TC101 Fall 2015 https://kenscourses.com/tc101fall2015 Introduction to Programming Python and C++ Wed, 25 Nov 2015 14:54:12 +0000 en hourly 1 https://creativecommons.org/licenses/by/4.0/ WSQ 16 – Cars https://kenscourses.com/tc101fall2015/2015/wsq-16-cars-2/ Wed, 25 Nov 2015 14:54:12 +0000 http://davidg2897.wordpress.com/?p=363 ]]> For this WSQ I used the book to know how to read files.

Here’s the working program.

Capture

Here’s the source code and my GitHub repository.

 

]]>
https://creativecommons.org/licenses/by/4.0/
WSQ15 – Images https://kenscourses.com/tc101fall2015/2015/wsq15-images-4/ Wed, 25 Nov 2015 14:44:05 +0000 http://davidg2897.wordpress.com/?p=342 ]]> For this WSQ I used the resources Ken gave us in the TC1014 page.

Here’s the working program. It’s really long because I gave the user options.

Capture

Here’s the image before and after

image
Before
image2
After

Here’s the source code and my GitHub repository.

]]>
https://creativecommons.org/licenses/by/4.0/
WSQ 14 – Estimating e https://kenscourses.com/tc101fall2015/2015/wsq-14-estimating-e/ Tue, 24 Nov 2015 15:44:37 +0000 http://davidg2897.wordpress.com/?p=331 ]]> For this WSQ I used this webpages:
Calculating value of e
e – Euler’s number

Here’s the working program

Capture

Here’s the source code and my GitHub repository.

 

]]>
https://creativecommons.org/licenses/by/4.0/
WSQ 13 – Babylonian Method https://kenscourses.com/tc101fall2015/2015/wsq-13-babylonian-method/ Tue, 24 Nov 2015 15:39:53 +0000 http://davidg2897.wordpress.com/?p=320 ]]> This WSQ I made it in class with Luis and some help from Ken.

Here’s the working program.

Capture

Here’s the source code and my GitHub repository.

 

]]>
https://creativecommons.org/licenses/by/4.0/
WSQ 12 – Greatest common divisor https://kenscourses.com/tc101fall2015/2015/wsq-12-greatest-common-divisor/ Tue, 24 Nov 2015 15:29:06 +0000 http://davidg2897.wordpress.com/?p=310 ]]> Here’s WSQ 12, I made it in class with Ken.

Here’s the working program

Capture

Here’s the source code and my GitHub repository.

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 28 & 30 https://kenscourses.com/tc101fall2015/2015/mastery-28-30/ Tue, 24 Nov 2015 02:52:21 +0000 http://davidg2897.wordpress.com/?p=298 ]]> Mastery 28 – User input (text based) in Python (basic)

Here’s basically any WSQ we’ve done, in most of them user input is needed.

Capture

Mastery 30 – Reading and writing of files in Python

Here’s an example code I made to demonstrate I know how to write and read files in Python.

Capture

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 26 & 27 https://kenscourses.com/tc101fall2015/2015/mastery-26-27/ Tue, 24 Nov 2015 02:34:43 +0000 http://davidg2897.wordpress.com/?p=285 ]]> Mastery 26 – Creation and use of strings in Python

Here’s Quiz 11 in which I used lines of a document, of type string to check for the banana word.

Capture

Mastery 27 – Creation and use of dictionaries in Python

Here’s the progress I have from WSQ17 in which I create and use a dictionarie.

Capture

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 23 & 25 https://kenscourses.com/tc101fall2015/2015/mastery-23-25/ Tue, 24 Nov 2015 02:27:41 +0000 http://davidg2897.wordpress.com/?p=271 ]]> Mastery 23 – Creation and use of lists in Python

Here’s WSQ10 in which I created and used a list.

Capture

Mastery 25 – Creation and use of ranges in Python

Here’s WSQ 14 in which is created and used a range in a for loop. You can algo assign it to a variable and use it for other purposes.

Capture

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 18 & 22 https://kenscourses.com/tc101fall2015/2015/mastery-18-22/ Tue, 24 Nov 2015 02:18:20 +0000 http://davidg2897.wordpress.com/?p=242 ]]> Mastery 18 – Nesting of conditional statements

Here’s WSQ 09, in which I use nesting of conditional statements.

Capture.JPG

Mastery 22 -When to use what type of repetitions on a program.

There are two types of loops in Python, while and for loops, when you want to make a repetition indefinite number of times to use a while, this will go until a condition is met. When you know the number of repetitions you need to make you use a for loops, which go the number of times you tell it to go.

Capture
This is a for loop from my WSQ 11
Capture
This is a while loop from my WSQ 06

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 08 & 09 https://kenscourses.com/tc101fall2015/2015/mastery-08-09/ Tue, 24 Nov 2015 01:59:46 +0000 http://davidg2897.wordpress.com/?p=196 ]]> Mastery 08 – The Zen of Python

Here’s the Zen of Python running inside my shell.

Capture

Mastery 09 – Basic type and their use in Python

Python has 6 different basic types of data. They are:

  1. Integers
    These are numbers that belong to all the real numbers.
    Capture
  2. Floating point numbers
    These are all the real numbers that use decimals.
    Capture
  3. Strings
    These are a set of letters, numbers or any other character. They are inbetween quotation marks (“”).
    Capture
  4. Tuples
    This is an ordered set of  values with fixed number of elements, goes inbetween parentheses.
  5. Lists
    This is an ordered set of values without fixed number of elements, goes inbetween brackets.Capture
  6. Dictionaries
    This is a type with different elements, used to map keys to their assigned values. They keys and values can be of any type.
    Capture

]]>
https://creativecommons.org/licenses/by/4.0/