From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to do this program?

Your first shot isn't using the phrase "amount tendered" properly.  That is the $30 your original post said you give the clerk.  You'd get change (or owe more) based on the gallons purchased multipied by the price minus the discount.  Your discount is only applied to the first fifteen gallons, so you need to figure if the purchase is for more or less and subtract accordingly. 

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 11 of 25
(951 Views)
Besides the basic arithmetic, you need a comparison to see if the purchase was 15 gallons or less. Based on the true/false result, you could use a case statement.
0 Kudos
Message 12 of 25
(950 Views)

thats what i was thinking of using, is a True False case statement.  Though i honestly dont know how to do the True False case structure.

0 Kudos
Message 13 of 25
(935 Views)

Also what would be the two cases and how would i conect them in order to show the discount amount and the final price indicators.

0 Kudos
Message 14 of 25
(924 Views)

Here's a hint on how to calculate the discount without a Case structure.  Make sure you understand how it works.

 

Untitled 2 Block Diagram _2014-09-06_19-31-21.png

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 15 of 25
(917 Views)

thanks that helps alot.

 

Now for the questions about the various symbols, what are they and where can i find them?

0 Kudos
Message 16 of 25
(911 Views)

@nyc_(is_out_of_here) wrote:

   [...]

  

   That is math I could have done in high school. [...]

You have learnt nothing in class?  Skipping class?


This seemed slightly harsh when I first read it, but you're not showing much to endear yourself to the collective.  Here are a few resources you should use:

 

LabVIEW Basics

LabVIEW 101

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 17 of 25
(905 Views)

Thanks for all the help guys.

 

I know it looks like im not trying here so im sorry for that.

0 Kudos
Message 18 of 25
(899 Views)

I expect that you recognize the "less than or equal to" symbol, the one next to it is "Select".  They're both on the Comparison pallet.  The multiply is on the Numeric pallet.

 

How have the tutorials helped?

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 19 of 25
(860 Views)

I figured out where the symbols are and such. 

 

Now i just need to figure out where to place the price per gallon.

 

Below is what ive got so far.  I placed the amount tendered to subtract from the final price to get he discount price.

 

Untitled.png

0 Kudos
Message 20 of 25
(848 Views)