Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Q1. For this PHP exercise, write a script using the following variables: Sx=80: Sy=20: 220=1048576 Use separated print statements to calculate and print the following

image text in transcribed

Q1. For this PHP exercise, write a script using the following variables: Sx=80: Sy=20: 220=1048576 Use separated print statements to calculate and print the following statements : ps. When you change the value of variables $x and $exp the output must be dynamically changed.pow(Sbase Sexponent) function could be used. The multiplication of 80 and 20 is 1600. The division of 80 by 20 results 4. The remainder of 80 after the divison by 20 is 0. When 20 reduced from 80 the result is 60. When we add 80 by 20 the result is 100. Q4. For this exercise, write a script using the following variable: Stxt= "He opened the file and saw that there were only thirty visible light images and twelve radar images of Deimos; Sstr="images": Srplc="problems"; Snumofchars=10: Socer="f ps. When you change the value of variables $x and $y the output must be dynamically changed. As a hint use variables while preparing the output. The script will display the following output: Q2. Write a script that will visit each character of a string and concatenate the characters of the string to form a word backward. At the end, your script must display: The text is "He opened the file and saw that there were only thirty visible light images and twelve radar images of Deimos" Yes, a palindrome Or No, your word is not a palindrome. The text includes "35" vowels. The text is formed from "20" words. Palindrome: is a word or sentence that reads the same forward as it does backward. Example civic, radar, rotor. ps. use strlen to find the length of a string. Restriction: Can not use strrevo function. When we replace "images" with problems" the text becomes He opened the file and saw that there were only thirty visible light problems and twelve radar problems of Deimos" The first 10 characters of the string are: "He opened" The last 10 characters of the string are: of Deimos" Q3. For this PHP exercise, write a script using the following variables: Sx=2; Sexp=20; The first occurance of "f* is "15". character. The script will display the power of $x starting from 0 up to Sexp using the format below: The uppercase version of the is: "HE OPENED THE FILE AND SAW THAT THERE WERE ONLY THIRTY VISIBLE LIGHT IMAGES AND TWELVE RADAR IMAGES OF DEIMOS" The power of 2s 20=1 21=2 22=4 23=8

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Making Databases Work The Pragmatic Wisdom Of Michael Stonebraker

Authors: Michael L. Brodie

1st Edition

1947487167, 978-1947487161

More Books

Students also viewed these Databases questions

Question

Describe Table Structures in RDMSs.

Answered: 1 week ago