-
Posts
1092 -
Joined
-
Last visited
-
Feedback
97%
Posts posted by Orange
-
-
4 minutes ago, Saiyan said:
Sike it's his birthday, according to snapchat
Credits to @Sysm for editing the cake
You'll always be TWC
Thanks bro, (its actually feb 17, but still the 16th here)
3 minutes ago, Mio said:2 minutes ago, Jordy said:Lol the gang.
gang gang
2 minutes ago, Jordan said:make a wish!
That one day everyone will realize that twc lives matter to!
2 minutes ago, AdnaneSen said:His face when he read the thread title :P fucking skemmer kid
at least I got a thread
2 minutes ago, ProjectPact said:REKT
1 minute ago, Sysm said:dank edit
Good looking cake
- 4
-
wew gz anne
-
who
-
that kid lifting weights is me, i'm that swole
-
yak
-
Insert/Remove Numbered Listjust mage them.
-
shout out 2 the plebs, if you wanna feel special go buy yourself a helmet and some crayons.
-
stick with jGRASP
-
shout out to all the kids with autism posting on this thread
- 8
-
Instructions/project requirements:
Tips given:
And here is my code atm:
Thanks in advance for le help , any tips or hints would be greatly appreciated, willing to teamview or do whatever if need be, also paying if you help me solve it
-
shit account
- 1
-
4 minutes ago, Mumble said:
Maybe just order of operations on line 20
at the end of it you do / x * y * z
The computer sees this as (NUMBER/x)*y*z
so maybe try to add paranthesis
Thanks so much !!! I feel like a noob for not thinking about this, I've spent hours over this past week trying to figure out what I did wrong in the equation and it never occured to me to put () around the xyz part , thanks man I owe you one
- 1
-
Ok so I'm basically done with my project, and I am given several different numbers to input to test it. When I type in 1 for the x,y, and z values I get the correct answer, but if I type in 2, 3, etc I get the wrong answer (I checked with a calculator). So I assume somewhere I typed my equation wrong or perhaps its executing in the wrong order.
This is the equation that I must use:
This is my code for the project, and the equation is on lines 20 & 38 (at the bottom is where I run the program with the 2 for x,y,z the answer should be around 7.8 but I get -94):
Thanks for the help
-
twc will do that to you sometimes
-
another day, still a tard
-
arkansas !
o, I thought you were from Alabama
-
he wild
-
I'm taking computer programming in school and we're doing Java in JGrasp and I'm failing to add a value to a integer I already have defined.
The program is a ticket calculator for speeding
1. All tickets will start with a minimum amount of $75.2. An additional $6 is charged for every mph over the posted speed limit.3. If you are traveling over 30mph over the posted speed limit, an additional $160 is charged.4. If the speeding occurred in a school zone, the cost of the ticket is doubled.Failing on step 2, and I'm new to java so don't judge my stupidity lol.System.out.println("What is the posted speed limit)? -->" );int speedlimit = Expo.enterInt();int ticketcost = 0;System.out.println("How fast was the car travelling in mph? -->");int speed = Expo.enterInt();if(speed > speedlimit){ticketcost+=75;}int excess = 0;speedlimit is the speedlimit of the area,speed is the speed of the car, and excess is every mile over,was gonna write something along the lines of speedlimit minus speed is the excess, and add multiplay excess by 6 and add it to my final ticket cost at the end of my program.sorry if I wrote this badly, I don't know how to explain it and its messy but I've tried writing it like 4 different ways and im confused lol. (We're using some online book and I'm just copying his skeleton for my work if it looks bad)1 // Lab07Ast.java
2 // The Speeding Ticket Program
3 // This is the student, starting version of Lab 07A.
4
5
6 public class Lab07Ast
7 {
8 public static void main(String args[])
9 {
10 System.out.println("Lab 07A, 100 Point Version");
11 System.out.println();
12 System.out.println("The Speeding Ticket Program");
13 System.out.println();
14 System.out.println("By: Drew"); // Substitute your own name here.
15 System.out.println("\n==============================\n");
16
17
18
19 System.out.println("What is the posted speed limit)? -->" );
20 int speedlimit = Expo.enterInt();
21 int ticketcost = 0;
22
23
24
25
26 System.out.println("How fast was the car travelling in mph? -->");
27 int speed = Expo.enterInt();
28 if(speed > speedlimit)
29 {
30 ticketcost+=75;
31 }
32 int excess=((speed - speedlimit) * 6);
33 if(excess >= speedlimit + 30)
34 {
35 ticketcost+=160;
36 }
37 ticketcost+= excess;
38 System.out.println("Did the violation occur in a school zone?");
39 char school = Expo.enterChar();
40
41 switch (school)
42 {
43 case 'Y':
44 case 'y':
45 ticketcost*= 2;
46 break;
47 case 'N':
48 case 'n':
49 ticketcost*= 1;
50 break;
51 }
52
53
54 System.out.println("Ticket amount: " + ticketcost);
55
56
57
58
59
60
61
62 System.out.println();
63 }
64 }
^ edit for tHE LAST TIME I actually got the riGHT ANSWER FINALLYRandom question what state do you live in ?
-
l000000000000l ???
Shits wild
-
retard
- 1
-
it say 64 day 7 hour but i dont believe it
-
???
- 1
-
I like it
-
need the following done:
haunted mine
itcharlin's little helper
ghosts ahoy
elemental workshop 2
wanted
slug menace
one small favour
contact
spirits of the elid
the giant dwarf
Orange no longer TWC
in Spam/Off Topic
Posted
thanks