PHP - Help Me With Some Exercises
QUESTION 1: Read two values, if variables A and B. Place the sum of variables A and B implying its result in the variable X. Present value of variable X after adding the two values.
QUESTION 2: The formula to calculate the area of a circle is A = pR2. Since the value of p = 3.14159 sufficient to establish: Read a value for radius, where the variable R. Perform the calculation of the area, boosting the value of R-squared and multiplying by p. Present value of variable A. QUESTION 3: Read two variables A and B. Then calculate the product between them and assign the variable PROD. Then show the variable PROD with corresponding message. Question 4: Read 2 variables A and B, which correspond to two notes of a student. Then calculate the average student, knowing that the note has a weight of 3.5 and a B weighs 7.5. QUESTION 5: Make an algorithm that reads four variables A, B, C and D. Then, if B is greater than C, and D is greater than the sum of A and C to D is greater than the sum of A and B and C and D, respectively, are positive and if the variable is the pair write the message "accepted values" but write "values are not accepted". I nee Help with those Php problems... i will need them solved till monday, because its my apliccatives final test day... Could someone help me? i already solved the question 2. <?php function achararea ( $raio ){ $circulo = $raio * $raio ; $area = pi () * $circulo ; return $area ; } ?> Could someone help me with the others? Similar TutorialsThis topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=331627.0 |