last day (17 days later) » 

16:36
Here we are..
hello
so I have this project
that is a command line interface parser
for java that has specific functions like -add -sub -mul -div -stats
etc
of course...
and ive done them but there are errors according to the test cases that I can't understand
and if possible I would like to just show you my entire code
and ask you a few questions
Ask me.. please
pastebin your code
this is what my project wants me to do.. : courses.cs.purdue.edu/cs18000:fall14:proj02
and these are the errors that i am getting : puu.sh/c1LMf/beff7783e0.jpg
16:43
ok... just give me a minute to understand what s going on...
are you on windows ??
which compiler you are using ?
dr java
yes windows
I am getting this error on compile...
I am using linux, and javac
[ ~/Documents/dev/StackOverFlow/java/myCLIParser ]
┏━┓ [ [ mlwn@xDeb ] / [ 10\06-16:47 ] ]
╺┛ Ⓒⓞⓜⓜⓐⓝⓓ
╹ ╺━╸/ javac MyCLIParser.java
MyCLIParser.java:25: error: cannot find symbol
else if (args[0].equals("-table")) table(args);
^
symbol: method table(String[])
location: class MyCLIParser
1 error
obviously, cannot find table
oh
sorry i havent done table yet so i didnt show you table
    private static void table(String[] args) {
        // CODE HERE
    }
thats all it is
at the end of the code
16:50
ok.. I commented it out anyway.. :)
kk
the joy of finding outa project is due in 24 hours and you didnt know about it
._.
how is that ??
well when i checked on friday i saw that the due date was a week from then but i checked last night and it was due today >.<
so ive been up all night trying to do this but its jsut not working out so i decided to seek for your help :p
sometimes it s a small thing.. let me read the code thoroughly ...
16:58
relax.. almost done.. :)
small mistakes.. as I said
kk
i dont know how i need to check my args array to see if the user input something that is nto an integer for example a string
like -add 1 cat will should be an error and i dont know if my code covers that probelm
wait.. there are other small things in the beginning
in the -sub... you want only two ??
or maybe more
only two
yes
like -sub 4 3 -> 1
ok.. perfect..
it is said in the project link i showed you
17:03
I don't have time to read that..
note i found an error in mult
all your errors are in array size my friend..
so yeah
so, don't worry
really how?
17:03
but do you want perfect code ? or you just want your code to work ?
i want the code to work to cover all the exceptions
:3
for example
Error handling:

If there is no argument after -add, print out an error message “Argument count mismatch”.
If any argument after -add is not an integer, print out an error message “Argument type mismatch”.
o.o
yo yo yo
try it now.. I fixed all array size problems
any questions ?
well my score got better!
but there is still problem of user input of strings where there should be integers
symptom: java.lang.ArrayIndexOutOfBoundsException: 2
at MyCLIParser.div(MyCLIParser.java:126)
at MyCLIParser.main(MyCLIParser.java:21)
For input string: "cat" (2 occurrences)

symptom: java.lang.NumberFormatException: For input string: "cat"
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.lang.Integer.parseInt(Integer.java:492)
at java.lang.Integer.parseInt(Integer.java:527)
at MyCLIParser.div(MyCLIParser.java:126)
at MyCLIParser.main(MyCLIParser.java:21)
(see full text)
is it showing also in add ?
or just in div
??\]\
I am doing a complete retouch.. but it takes time...
agree ?
what's the time now ? and how long do you still have ?
I HAVE
10 hours and 40 minutes
and i believe the error is only in
division, main and stats..
but not entirely sure
also thank you so much for helping me it means a lot!
17:25
Please, you are tired.. take a break.. drink a juice.. :)
I will redesign your code.. you'll like it.. trust me..
thank you...
17:46
you'll like my work :)
hope you didn't fall asleep... :)
Trying to intertain you at same time.. :)
Hellooooooooo
:)
almost ready
18:08
oh hello
sorry was looking at something :p
hello? :3
finished
perfect code
:)
try to find an error now...
oh wow you did table?
:( i wanted tot ry that my self hehe
of course
lol
just run the code..
I felt sad that you are tired..
O.O there is more wrong here
please.. run it a couple of times.. because I didn't try it enough
where ?
paste error
18:16
wait let me see
maybe its because of the string errors
there should no more be strings errors
it's controlled
I am system.out.println("Error: etc etc etc... ")
lol
I know
the system that checks for me
has specific examples so
ahhhh
ok
the error should say "Argument count mismatch" etc etc
same style
ok ok
18:18
ill change it 1 sec
perfect...
you need to change all over the code..
or write a function that handles those and call it...
Estimate of Problem Coverage (80%)
The following hint(s) may help you locate some ways in which your solution may be improved:

Check if division is working correctly

Table output should exactly match the format specified in the handout

Check if you are subtracting correctly
ok... for table output, try "%6d" instead of "%4d"
Estimate of Problem Coverage (95%)
sub and div not working properly i think i.i
one minute
lol
I didn't know you have such system...
18:22
im not sure why
because of double
fix div to following
System.out.println((double)Integer.parseInt(args[1]) /
Integer.parseInt(args[2]));
instead of
System.out.println(Integer.parseInt(args[1]) /
Integer.parseInt(args[2]));
now what ?
i found the sub error
u did args[2] - args[1]
:)
lol
what about the div.??? did you try it ?
not yet once sec
also, you should print it the same way we did for average
System.out.printf("%.2f\n", (double)Integer.parseInt(args[1]) / Integer.parseInt(args[2])));
18:26
:)
thank you sooooo much!!!!
don't worry
can i ask you
\just next time.. do your work on time...
ask
how you handled the problem of strings
:)
18:27
in the arg
the isInteger thing
if (!isInteger(args[i])) check = false;
hmm wierd i did the same but it didnt work
oh well :p
later... if check, do the work, otherwise, print that the thing has a problem
thank you so much!!
you didn't organise your code.. you were doing so many if-else... without structuring them
18:28
Is there a way I can add you somewhere to ask you for advise if I need? :3
of course.. you can always drop me an email
michel.alwan@yandex.com
but next time, never leave yourself till last minute
I normally don't do this.. but I felt bad and wanted to help...
:P thank you so very much!
that's why I didn't leave the table for you to write..
:)
I mean its not like I dont ask people to do my work for me
normally, I just guide you, and leave you to do the thing on your own
18:29
just needed some help on somethings
ya.. it's ok..
yes that is what I like
where are you from?
u studying this in university ?
yes
im a 1st year comp sci student
cool..
18:30
what about you?
I learnt all the programming i know on my own
to solve my own problems in life
I am a mechanical engineer.. with 9 years experience in mining ..
I work in Africa
oh WOW
i lived in africa
where ?
for 5 years
in Nigeria
lol
i lived there 5 years too
what did you do there ?
18:31
:D i went to high school there
my dad was an engineer for chevron there
parents ?
wow...
what's your name ?
Rohan :)
from ?
18:32
you can add me on facebook if you want
Im from India
I have no facebook...
i live in Indiana now though
one minute
where in africa are you?
Currently in Ghana...
by the way, since you are open for learning
do you know Richard Stallman ?
18:34
no... who is he
wiki this person.. and check his website..
I think you'd change alot when you read .. about the truth
:)
cool o.o
he's a great guy... without him, you probably wouldn't be writing java today... :)
:P
i went to ghana several times
i played football there in acra
hehe
nice..
18:37
where are you from?
send me later an email.. we can stay in touch..
oikay definetly!
I am from Lebanon
and whenever you need advice.. in anything.. don't hesitate.. :) my pleasure.
ok thank you merci beacoup :)
talk to you later!
my email is rohan.vidy@gmail.com
btw
good.. :)
take care.
just sent you an email.
18:42
ok

  last day (17 days later) »