TutorMe homepage
Subjects
PRICING
COURSES
SIGN IN
Start Free Trial
Pranish A.
Software developer at Switchme technologies
Tutor Satisfaction Guarantee
PHP Programming
TutorMe
Question:

Write php code to print a random number from 50 to 1000?

Pranish A.
Answer:

<?php echo(mt_rand(50,1000)); ?> - php code is always written inside <?php ?> tags - echo() is a php function to print anything on web page. - mt_rand() is a function which take 2 parameters. 1st is min val and 2nd is max value. It prints out a random number between min and max values

Javascript Programming
TutorMe
Question:

Write a function that alerts "Hello World" every 5 sec?

Pranish A.
Answer:

function sayHello() { setInterval(function(){ alert("Hello"); }, 5000); } setInterval() is a js built in function that takes two parameters. 1st is function to be called and 2nd is time in ms ,after we call the function.

HTML Programming
TutorMe
Question:

What will html code to add background color to an element?

Pranish A.
Answer:

The code will be : <div style="background-color:yellow;">This is Yellow</div> style attribute here is called inline styling in html which is used to define css for any particular element. Syntax: <div style="" ></div> css is put inside style attribute. e.g :- you can put color, backgroud-color, font-size,etc

Send a message explaining your
needs and Pranish will reply soon.
Contact Pranish
Ready now? Request a lesson.
Start Session
FAQs
What is a lesson?
A lesson is virtual lesson space on our platform where you and a tutor can communicate. You'll have the option to communicate using video/audio as well as text chat. You can also upload documents, edit papers in real time and use our cutting-edge virtual whiteboard.
How do I begin a lesson?
If the tutor is currently online, you can click the "Start Session" button above. If they are offline, you can always send them a message to schedule a lesson.
Who are TutorMe tutors?
Many of our tutors are current college students or recent graduates of top-tier universities like MIT, Harvard and USC. TutorMe has thousands of top-quality tutors available to work with you.