SHARE

TWEET

# Gottabemoist's code

a guest
Jan 22nd, 2020
74
Never

**Not a member of Pastebin yet?**

**, it unlocks many cool features!**

__Sign Up__- //This is the question
- //– Write a function that determine the total daily income from Miller’s Car Rental; the
- //function will accept three parameters/arguments and return a value; make sure that the
- //function can be used by other programs if needed. (Note: for this use local and global
- //variables, if needed)
- //Using the same information, build a rectangle filled with “$” that has a base and height
- //equal with 2 of your information like below (your choice):
- // $$$$$$$$$$$$$$$$$$$$$
- // $$$$$$$$$$$$$$$$$$$$$ height
- // $$$$$$$$$$$$$$$$$$$$$
- // $$$$$$$$$$$$$$$$$$$$$
- base
- //This is what ive got so far
- function daily() { //this is the function
- let n = prompt("How many necessity vehicles?"); //This is the prompt for the necessity vehicles
- let Member = prompt("Whats the total of the members purchase vehicles"); //this is the prompt for how many members purchsed vechicles
- let NonMember = prompt ("Whats the total of the non-Member purchase vehicles"); //this is the prompt for how many non memebers purchased vehicles
- let tN
- tN = n*55 //Necessity vechile multiplied by 55
- let totalMember
- totalMember = Member*75 //How many members multiplied by 75
- let totalnonMember
- totalnonMember = NonMember*85 //How many non Members multiplied by 85
- let total
- total = totalMember + totalnonMember + tN //Total number of members plus total number of non members plus number of necessity vehicles
- return total.toFixed(2)
- console.log("The everyday income total =" + total) //To display the total
- }
- daily()

RAW Paste Data

We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy.