Author Archives: Juan Pablo Barberena

#TC1017 #wsq15: Course plan

So, only two weeks and a half until the end of classes, plus the final exam. Here is my plan about all the activities for this final period, including one weekly WSQ, and one weekly Quiz. Fortunately, I got a lot of Masteries points, so I won’t be needing to do a lot of them. That way, I have more time to work on the project (as well as other subjects’ projects).

Here it is:

#TC1017 #QUIZ09: Exam solutions

Hey! Here are all the solutions to the 2nd partial exam:

Question 1: https://github.com/JPBarberena/Codes/blob/master/q01.cpp

Question 2: https://github.com/JPBarberena/Codes/blob/master/q02.cpp

Question 3: https://github.com/JPBarberena/Codes/blob/master/q03.cpp

Question 4: https://github.com/JPBarberena/Codes/blob/master/q04.cpp

 

To correct my mistakes, I took a look at my anterior codes, but for the second question, I found a very helpful resource in this page: http://bytes.com/topic/java/answers/931543-how-do-i-raise-any-number-x-positive-power-n-using-loop

 

#TC1017 #mastery27: Validating user input

Hey! I created another PDF tutorial showing how to stop users from messing around with your programs by entering values that don’t correspond to the instructions. Hope you like it!

https://drive.google.com/open?id=0B7w3BFfqL9oQVFBubjJYRVBJbDA&authuser=0

#TC1017 #wsq14: Calculating e

This is my code for WSQ14. I had some problems finding out how to truncate the decimals, because the function I was using rounded them, so instead I used strings… I converted the double variable to a string, I applied .substr, and then I converted back to double. This way, decimals were truncated in the precision given, instead of being rounded.

Here is the code:

https://github.com/JPBarberena/Codes/blob/master/wsq14.cpp

#TC1017 #mastery04: Submit work via RSS and Github

Hey! I created another PDF tutorial for Mastery , although I think I did it a little late. Anyways, here is the link to it:

https://drive.google.com/open?id=0B7w3BFfqL9oQeFlSRDBfZmxaVHM&authuser=0

#TC1017 #mastery08: Coding Conventions

Hey!! I created another PDF tutorial showing some of the basic conventions to write a clean and neat code, in order to make it more understandable and readable to other people. Hope you enjoy!!

https://drive.google.com/open?id=0B7w3BFfqL9oQYXFyY052OW5QeHM&authuser=0

#TC1017 #mastery21: Recursion

Hey! I created another PDF tutorial showing recursion with the factorial program. Hope you enjoy!!

Here’s the link:

https://drive.google.com/open?id=0B7w3BFfqL9oQVkg1Ml9zakgtSVU&authuser=0

 

#TC1017 #wsq13: Babylonian Method

At first it was a little confusing, but with a simple do-while loop I managed to get this working.

Here’s the code:

https://github.com/JPBarberena/Codes/blob/master/wsq13.cpp

#TC1017 #wsq12: GCD

This was a relatively easy WSQ. Here’s the link for Github:

https://github.com/JPBarberena/Codes/blob/master/wsq12.cpp

#TC1017 #wsq11: Lychrel Numbers

Finally I got this running!! It took me a lot of time to write this code, since I got lost a lot! It was a very challenging work, but I’m finished now! Here’s the link to Github, hope you find it useful for your code!

https://github.com/JPBarberena/Codes/blob/master/yosoy196/yosoy196.cpp