Monday, January 23, 2017

Lab #9

For lab 9 we had to create a validation form of our own based on our html and javascript knowledge. The first thing to do was to create a table and fill it into what was name, last name, gender, date of birth, email address, telephone number and the address where the user resides. Creating a validation online form was a very interesting to do because we did not only learn a new skill but also because just in case later on we want to create a website to like for example sale some product, then we could use this to integrate a page for the user to enter their shipping information and of course personal information. Another thing I learned is that we are not supposed to as for the persons social security if the website isn't governmentally approved. It is illegal to do so. Overall not many of us were able to complete this project but for all we know is that certain skills were reinforced and that we of course learned how to manage our time more wisely.

Calculator Project

For project #1 we had to create a calculator using mostly JavaScript. This was probably the hardest project we had to complete during this semester because even though we had more than enough time to do, most of us keep focusing on the design than actually making it work and personally it was kind of too late when I noticed. This project was hard because it required a lot of research on our own of something that we barely had knowledge of. This project will be useful for our future because now we have developed skills on knowing how to work with operations and specially if it is a calculator because it really looks appealing at any time you want to make your website more professional looking. I liked the fact that even though we didn't learn much about calculators and operations at the beginning, we were able to figure it out. Our teacher would every day teach us something knew which I found to be a very smart method because for something so complicated like this, she went little by little in order for us to slowly swallow the information we received.

Lab 8

Lab 8 was a quick demonstration of the different kinds of loops. Loops are handy whenever you want to run the same code over and over again, with each time executing a different value. Loops can execute a block of code a number of times. There are four different kinds of loops. The for loop, the for/in loop, the while loop and the do/while loop. The for loop is often the tool you will use when you want to create a loop.

            Syntax is
                  for (statement 1; statement 2; statement3)}
                            code block to be executed
                  }
       *Where as statement 1 is executed before the loop starts, statement 2 defines the condition for       running the loop and statement 3 is executed each time after the loop has been executed.
  • The for/in loop are loops through the properties of an object.
  • The while loop can execute a block of code as long as a specified condition is true.

            Syntax is
                  while(condition) {
                             code block to be executed
                   }
  • The do/while loop is a variant of the while loop. It will execute the code of block once, before checking if the condition is true, then it will repeat the loop as long as the condition is true.
            Syntax is
                 do{
                         code block to be executed
                     }
                 while (condition);

Thursday, January 12, 2017

WBL Workshop #2

Yesterday Monday 19th was the child labor laws and workplace safety workshop conducted by Ms. Lopez for all the CTE academy students which included video production and web design. Personally this workshop was very helpful for me because I am currently in the process of having my intership done and as a worker I made sure I knew my rights and all the procedures. First we were explained that the minimum wage was nine dollars, that we have the right to a safe work place and if this isn't happening then we have the right to file a complaint. We went over the jobs that one as a minor is allowed to do, also the amount of hours we are supposed to complete including the hours we are allowed during the holidays which are 4hrs from Monday to Thursday during school days and up to 8hrs Friday, the weekend and during holidays. One thing that I found very useful was certain things that the person that hires you asks you to do but you by law aren't supposed to. This is important because for some students they just go to their work place without any knowledge of these things. Another thing I found interesting was the sexual harassment topic. Sometimes people agree to their boss's orders because they do not want to lose their jobs or because they are not exactly aware of the signs. Sexual harassment could happen at any time, at any place and to anyone. We were told that if we felt uncomfortable at the work place for some reason, to inform our counselor or someone we feel okay talking about it with because we are all protected by our own union. We also entered into the proper equipment discussion which for the major part it's just about knowing that you have the right to acquire a separate time of just training so you could within that time ask any questions and be thought of how to use any equipment that you are asked to. The last area we went over was a review of how important it is to preserve a good communication with the person that hires you. It is important for you and this person to find different ways to communicate,  this in case someone happens to you and you can't attend to work that day then they'll know and you'll just end up being the responsible one for making sure that they knew. Communication is just the key to work at a safe and comfortable environment.

Tuesday, January 3, 2017

Booleans

JavaScript booleans represent either true or false values. We use Boolean() function to determine whether an expression is true or not. To compare conditions you can use equal to (==), greater than (>) and less than (<) symbols. This operators can be used to determine equality or difference between variables and values. You may also use (!=) to determine that the two expressions are not equal to each other. You could also use operators to assign a value to a variable based on some condition. So for example you want to come back with a certain statement based on the users condition, you can use the following line

     variablename = (condition) ? value1:value2
 in which case value one would return "You are old enough" and value two would return "You are old enough".