I did the trace. It's solved. With an if loop at the bottom.
Type: Posts; User: einar123
I did the trace. It's solved. With an if loop at the bottom.
Hi. This where I'm at right now.
The error comes when I test for sequence 1 3 3 5 4 2 3
package forrit;
public class Verkefni2tplus {
Ok. I have a string in the array?
--- Update ---
Whitespace?
--- Update ---
It's the commas!
Thanks jps. I think directly. But my program is not correct. I'll put up a new post.
--- Update ---
The invariant is supposed to be something like this:
1.F-->I
2.I ^ not R}S{I}
3.I ^...
Ok. Does anyone in Java-universe know why this code is giving 5 for this sequence:
0,0,5,79,8,8,7,4
--- Update ---
Ahh-sorry-that is correct?!
--- Update ---
I'm wondering. This is a...
Mr.Jps. I find it so difficult to read this kind a stuff...I'll always get the sleepreading syndrome we see this, and just give up. Sort of like when I read my terrible tabing(syntax) in me last...
Ok. Is this as bad as the last one?
And is'nt this the: We solve your homework forum?
package forrit;
public class Longesdecreasingttt {
public static void main(String[] args) {
Ok. Would you give correct for doing it this way?
public class LongestDecreasing {
public static void main(String[] args) {
int N = args.length;
int[] a = new int[N];
...
My problem now is that I dont ,,take'' the number in a0. But I feel like I'll have to have i=1 because if I have i=0 then I'm out of bounds....but then again I'm out of bounds at the other end...
hahahah I'l admit that I'm forum timid
GregBrannon. The System.out print...I'm just not cutting it
args should be = i
I think I'm almost there.
How can I fix this code so that it works?
public class VectorDecreasing {
public static void main(String[] args) {
int N = args.length;
...
Excuse me. Code tags? I did highlight. Do you mean like explanation in the code itself? Meesa don't understand this.
My problem is I dont know where start really. Not asking for soloution, just...
Just started to work at this problem.
Any suggestions?
public class LongestDecreasing {
public static void main(String[] args) {