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
‘TC0107’ Articles at TC101 Fall 2015 https://kenscourses.com/tc101fall2015 Introduction to Programming Python and C++ Thu, 08 Oct 2015 21:13:38 +0000 en hourly 1 https://creativecommons.org/licenses/by/4.0/ #Quiz06 https://kenscourses.com/tc101fall2015/2015/quiz06-2/ Thu, 08 Oct 2015 21:13:38 +0000 http://eduardomacielm.wordpress.com/?p=110 Hi, here are my answers to the #Quiz06 questions:

q1.cpp

q2.cpp

]]>
https://creativecommons.org/licenses/by/4.0/
Masteries 11 & 12 https://kenscourses.com/tc101fall2015/2015/masteries-11-12-2/ Fri, 18 Sep 2015 21:35:32 +0000 http://eduardomacielm.wordpress.com/?p=107 ]]> In this short video I explain how to create and call a simple function to print it with a “cout<<“.

]]>
https://creativecommons.org/licenses/by/4.0/
Mastery 7 https://kenscourses.com/tc101fall2015/2015/mastery-7-2/ Fri, 18 Sep 2015 00:17:49 +0000 http://eduardomacielm.wordpress.com/?p=104 ]]> Hey, this video about how to comment in C++ was really short but I’m sure it’s enough. Hope you like it.

]]>
https://creativecommons.org/licenses/by/4.0/
Masteries 5 & 6 https://kenscourses.com/tc101fall2015/2015/masteries-5-6/ Fri, 18 Sep 2015 00:10:11 +0000 http://eduardomacielm.wordpress.com/?p=101 ]]> Hi again! Here’s my video for masteries 5 & 6. I’m sorry for the awful edition and also for the excessive use of the Benny Hill’s Theme. I hope you like the video even with that stuff.

]]>
https://creativecommons.org/licenses/by/4.0/
Masteries 3 & 4 https://kenscourses.com/tc101fall2015/2015/masteries-3-4-3/ Thu, 17 Sep 2015 21:21:04 +0000 http://eduardomacielm.wordpress.com/?p=91 ]]> Hi everyone, here’s my video tutorial for masteries 3 and 4 (in Spanish). I hope you like it, and I also hope to get the 4 points for this video.

 

]]>
https://creativecommons.org/licenses/by/4.0/
#WSQ07 Sum of Numbers https://kenscourses.com/tc101fall2015/2015/wsq07-sum-of-numbers-10/ Tue, 15 Sep 2015 17:24:23 +0000 http://eduardomacielm.wordpress.com/?p=79 Continue Reading →]]> This task was a little harder, because you had to use more complex logical functions, like a loop, and some other I will explain here.

  • In my code I’m using the variables x , y, and z to operate, being x: the first bound; y: the second; and z: the operator, which is going to sum with x until it reaches y. (Check the code to get it).
  • From line 17 to 21 I use this (below) to handle with the trouble of the user imputing the bounds in the wrong order, being <m> a variable that takes the value of <x> temporally after giving it to <y>.

if (x>y){

m=x;
x=y;
y=m;
}

  • I also use the variables <xx> and <yy>, which are <x> and <y> respectively, so at the end, when you print the result, it prints the original bounds you gave, and not the values they took while doing the operation.
  • If you ask to play again (or try again), you should give back 0 to the values of all the integers, so, if the user tries again, it doesn’t give a wrong sum.

https://github.com/EduardoMacielM/TC1017/blob/master/Sum.cpp

]]>
https://creativecommons.org/licenses/by/4.0/
#WSQ06 Pick a Number https://kenscourses.com/tc101fall2015/2015/wsq06-pick-a-number-9/ Tue, 15 Sep 2015 16:55:32 +0000 http://eduardomacielm.wordpress.com/?p=77 Continue Reading →]]> Hi there people. This task was a little different, because you had to use another library, and some different functions.

  • The library <ctime> or <time.h> which is the same, is used here to measure time, so you can generate a new random number every time you run the program.
  • The variables I use are x: for the random number; y: for the number you enter; and i: for the counter.
  • In the line 16 of my code I’m using the symbols <  ||  >, which is the logical function OR.
    if (y<=0 || y>100) {
    cout<<endl;
    cout<<Remember that the number should be between 1 and 100…<<endl;
    }

So what the code stated for the if, will run when one OR another condition is TRUE.

  • Everything else in the code is easy and you should’ve used it for some previous WSQ’s.

https://github.com/EduardoMacielM/TC1017/blob/master/random.cpp

]]>
https://creativecommons.org/licenses/by/4.0/
#Quiz04 https://kenscourses.com/tc101fall2015/2015/quiz04-13/ Tue, 08 Sep 2015 00:19:10 +0000 http://eduardomacielm.wordpress.com/?p=71 ]]> Well there’s nothing to say, my blog exists, is registered, and I’m logged in to http://kenscourses.com/tc101fall2015

Captura de pantalla 2015-09-07 a las 9.14.19 Captura de pantalla 2015-09-07 a las 19.07.37

]]>
https://creativecommons.org/licenses/by/4.0/
#WSQ05 Temperature https://kenscourses.com/tc101fall2015/2015/wsq05-temperature-9/ Wed, 02 Sep 2015 01:45:48 +0000 http://eduardomacielm.wordpress.com/?p=44 Continue Reading →]]>

Hi again everybody!

This post is about another easy c++ task you can do with the basic operators you have used before. The program has to convert from fahrenheit degrees to celsius, and tell you if water boils or not at the temperature you typed.

Some stuff you should know before:

  • The variable type float is used to introduce or operate with a number with decimals.
  • Include the library <iomanip> to use the function setprecision  which lets you set the number of decimals that you’ll use with the float variable.
  • Use the command “<<fixed <<setprecision(n) <<x; cout<<“. Being n = the number of decimals you want; and x = the float variable.

#include <iostream>
#include <iomanip>
using namespace std;

int main (){
float f, c;
char ans;
do  {
cout << “What is the temperature in Fahrenheit?” <<endl;
cin>> f;
c=(5.0 * (f-32) / 9.0);
cout<< “The temperature of “<<fixed <<setprecision(1) <<f; cout<< ” degrees Fahrenheit is ” <<c;         cout<< ” degrees in Celsius.” <<endl;

  if (c >= 100) {
cout<<“Water does boil at this temperature”<<endl;
}

  else {
cout<<“Water does not boil at this temperature(under typical conditions)”<<endl;
}

cout<< “Do you want to convert again? (y/n)”;
cin>> ans;
}
while(ans==’y’);
return 0;
}

As a plus, I added the option to run the program again, without typing the ./a.out (./a.exe in Windows) just by answering the question: “Do you want to convert again? (y/n)”. I did this using:

do {/* code */}

while(/* condition */);

Check my code and if you have a question please comment or ask me by twitter.

Thanks!

]]>
https://creativecommons.org/licenses/by/4.0/
#WSQ04 An About Page https://kenscourses.com/tc101fall2015/2015/wsq04-an-about-page-7/ Tue, 01 Sep 2015 23:16:09 +0000 http://eduardomacielm.wordpress.com/?p=39 Continue Reading →]]> Hi everyone! Hope you all enjoyed your weekend, because tomorrow we’ll be back to the hell we often call Monday.

In this post I’m going to introduce myself properly and give some information about me.

My full name is José Eduardo Maciel Mendoza, but just leave it as Eduardo Maciel.

I just started my career in Biomedical Engineering at the Tecnológico de Monterrey campus Guadalajara.

I was born in Macuspana, Tabasco, but my parents are from Jalisco, so that’s why I decided to come to study college here.

My heroes are my parents, who have always being supporting me and cheering me up.

I also have 2 sisters, 3 and 6 years older than me.

IMG_5370

I’m in a relationship of 18 months, which turned to be a long distance 2 months ago.

I like music, and I can play the guitar, bass, and some drums basics. I have 4 guitars, but I could only bring my 2 favorite with me.

IMG_4797
My babies <3

In my free time, I like to play xbox, or learning about new technologies, and I also like cars (maybe you have noticed it before).

I like traveling and visiting new places and cities. I would like to travel over the world, specially to Dubai, but I think I should first know every place in Mexico, because it’s not as small as you may think.

Here are a couple of pictures I took in a trip to Palenque, Chiapas, which is only 1 hour away from my home in Tabasco.

IMG_6933
Panoramic picture from the highest point in Palenque
IMG_6950
Misol-Ha waterfall, located 20 kilometers from the archeological site of Palenque

…And that is only a couple of nice places you maybe haven’t visited yet.

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