#comparison yields wrong output

1 messages ยท Page 1 of 1 (latest)

golden baneBOT
#

<@&987246399047479336> please have a look, thanks.

crimson spear
#

the 3 pictures i have sent on my issues that are coming out

night gull
#

could u please give a quick explanation of the task and guide us through ur code? also please post the code as formatted code block with syntax highlighting and elaborate on what's unclear to u in particular

crimson spear
#

yes

#

i can send you the code

#

import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a;
  int b;

  System.out.println("Enter two positive integers, the first smaller than the second.");

    do {
        System.out.print("First: ");
        a = in.nextInt();
        System.out.print("Second: ");
        b = in.nextInt();

        if (a >= b) {
            System.out.println("Invalid input. The first number must be smaller than the second. Please try again.");
        }
    } while (a >= b);
  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
}

golden baneBOT
#

comparison yields wrong output

#

Changed the title to comparison yields wrong output.

#

Please use this format for posting code:

```java
// Example java program
int value = 5;
System.out.println(value);
```

Which results in:

// Example java program
int value = 5;
System.out.println(value);

For syntax highlighting, you have to add the name of the language after the three backticks, like ```java. Please make sure to use exactly this format, so no space between the backticks and the language name, and a newline before the code starts. If done right, the syntax highlighting will even be applied to your text as you type, before sending.

crimson spear
#

oh

night gull
#
  1. could u please give a quick explanation of the task
  2. and guide us through ur code?
  3. also please post the code as formatted code block with syntax highlighting
  4. and elaborate on what's unclear to u in particular
#

u have a tendency to only read half of whats been asked

#

once u addresses all 4 items, people will be able to help u ๐Ÿ™‚

crimson spear
#

import java.util.Scanner;

public class TwoNumbers {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);

    int a;
    int b;

    boolean validInput = false; // This boolean variable is used to control the loop

    while (!validInput) {
        System.out.println("Enter two positive integers, the first smaller than the second.");
        System.out.print("First: ");
        a = in.nextInt();
        System.out.print("Second: ");
        b = in.nextInt();

        validInput = (a < b); // Check if the first number is smaller than the second

        if (!validInput) {
            System.out.println("Invalid input. The first number must be smaller than the second. Please try again.");
        }
    }

    System.out.println("You entered " + a + " and " + b);
}

}

#

code issues

#

i am looking at where i did wrong

#

i am not now sure what i did wrong

#

it wants a code

night gull
#

please do the 4 things i asked u to do

#

ur just ignoring it

crimson spear
#

i see it

#

i am not ignoring it

night gull
#

okay. so lets start with point 1.

#

explain the task. what are u supposed to solve/do

crimson spear
#

The Scanner class is used to take input from the user.
Two integer variables a and b are declared to store the user's input.
The boolean variable validInput is initialized to false to control the loop.
The do-while loop continues until validInput becomes true.
Inside the loop, the user is prompted to enter two positive integers with specific messages for "First:" and "Second:".
The validInput is set to true if the condition (a < b) is satisfied, meaning the first number is smaller than the second.
If the input is not valid, an error message is displayed, and the loop continues.
Once a valid input is provided, the loop exits, and the entered values are displayed.
Regarding the error:

The error you encountered (variable a might not have been initialized and variable b might not have been initialized) occurs because the compiler cannot guarantee that variables a and b have been assigned values before their use in the System.out.println statement. To resolve this, you can either initialize a and b with default values when declaring them or use a do-while loop instead of a while loop to ensure they are assigned values within the loop.

night gull
#

that sounds like u asked chatgpt to solve ur issue and explain ur code

crimson spear
#

yeah but i still don't get it

night gull
#
  1. could u please give a quick explanation of the task
  2. and guide us through ur code?
  3. also please post the code as formatted code block with syntax highlighting
  4. and elaborate on what's unclear to u in particular
#

once u did that, we will help u

crimson spear
#

About the Error:
The computer sometimes gets worried that we are using the numbers a and b in the last sentence before the person has even given us any numbers. We need to convince the computer that we will only use a and b after we are sure the person has given us the right kind of numbers. We do this by using a special loop called do-while.

night gull
#

ill just stop responding until u did all 4 things now.

mighty olive
#

and use your own words , not some copy paste from the assignment

crimson spear
# night gull ill just stop responding until u did all 4 things now.

We use a special tool called Scanner to talk to the person using our program.
We have two boxes (a and b) to keep the numbers that the person types.
We also have a special switch (validInput) that helps us decide if the numbers are correct or not.
We use a special loop called do-while to keep asking for numbers until they give us the right ones.
Inside the loop, we ask for the first number, then the second number.
We check if the first number is smaller than the second. If it is, we say everything is good by turning on the validInput switch.
If the numbers are not right, we say that and keep asking again.
Once the person finally gives us the right numbers, we exit the loop and tell them what they entered.

crimson spear
crimson spear
#

of ur questions

night gull
#

u did not.

crimson spear
#

i did

#

look at it

night gull
#

i did look at it. I'm reading all ur messages

crimson spear
#

okie

#

i really help with this code

#

why do i have repeat my self lol

night gull
#

i know. that's why im offering u my help. after u did the 4 steps

#

u did none of them so far

crimson spear
#

i did

#

bro

#

i have answered it

#

never mind

mighty olive
#

cause your very unclear and your refusing to actually read anything. Even your own error screen which has the actual solution

crimson spear
#

i will answer it again

golden ermine
#

that's one of the most ridiculous asking for help i've ever seen

#

desbribe the problem with your own words, so that you can also understand it and paste a FORMATTED code, not just pasted in plain text because it looks like shit

night gull
#

thanks

crimson spear
#

people that just texted are rude

night gull
#

lets do it together, step by step

crimson spear
#

yes

night gull
#

step one, please explain me what ur task is about

crimson spear
#

the task i need a code for this

night gull
#

what is "this"?

crimson spear
#

and i wrote my code down

#

i sent the picture and everything

night gull
#

does ur code have to compute a + b?

crimson spear
night gull
#

so ur supposed to add two numbers together?

crimson spear
#

when i runed it it gave me an error

night gull
#

or multiply them?

crimson spear
#

yes

#

add

night gull
#

or divide them?

#

okay

#

so if i enter 3 and 7, u have to output 10?

crimson spear
#

boolean validInput = false;

    while (!validInput) {
        System.out.println("Enter two positive integers, the first smaller than the second.");
        System.out.print("First: ");
        a = in.nextInt();
        System.out.print("Second: ");
        b = in.nextInt();

        validInput = (a < b);

        if (!validInput) {
            System.out.println("Invalid input. The first number must be smaller than the second. Please try again.");
        }
    }
#

this is what i wrote just now

#

for that

night gull
#

that code doesn't add two numbers together

crimson spear
#

and i got an error

night gull
#

u just said ur supposed to add two numbers. ur code doesn't add two numbers at all

#

could u please stop doing random stuff

#

stick with me

crimson spear
#

ok ok sorry

night gull
#

read what i say, respond to what i say

crimson spear
crimson spear
night gull
#

are u sure u have to add two numbers?

crimson spear
#

Complete this program, prompting the user to enter two positive numbers a and b so that a is less than b.

night gull
#

i know, i can read that myself

#

i feel like u don't understand the task. so ur not supposed to add two numbers together at all

crimson spear
#

i have make it less then b

night gull
#

anyways. next step. please post ur code as formatted text with syntax highlighting

#

heres how to do it :

golden baneBOT
#

Please use this format for posting code:

```java
// Example java program
int value = 5;
System.out.println(value);
```

Which results in:

// Example java program
int value = 5;
System.out.println(value);

For syntax highlighting, you have to add the name of the language after the three backticks, like ```java. Please make sure to use exactly this format, so no space between the backticks and the language name, and a newline before the code starts. If done right, the syntax highlighting will even be applied to your text as you type, before sending.

crimson spear
#

yeah i know

#

but i don't know what to i am confused

night gull
#

what's unclear to u

#

i can't help u if all u say is "im confused"

#

confused on what exactly?

#

what can i explain in more detail to help u?

crimson spear
#

๐Ÿ˜•

mighty olive
#

what do u not understand about the last thing ?

crimson spear
#

The error message you are seeing is because the variables a and b might not have been initialized before they are used in the System.out.println statement. This error occurs when we declare a variable without initializing it

mighty olive
#

the last thing Zabuzard asked from u. Please try to respond to the questions and not do random things

crimson spear
mighty olive
#

It might feel weird, but its yourself that it blocking yourself from getting help, if u can be clear and try to respond in normal matter, this issue could of been solved more then an hour ago

night gull
#

please post ur code as formatted text with syntax highlighting
ive explained how to do it here:
#1195379743013482626 message

mighty olive
night gull
#

is that really what u want?

crimson spear
# golden bane

// Example java program
int value = 5;
System.out.println(value); idk where this goes

night gull
#

ur missing the backticks and everything

#

read the message fully

tired ingot
#

please just answer like Zabuzard requested

crimson spear
#

and i wanted to know why

#

thats all

#

they don't have to be rude

tired ingot
#

Because you're making it very hard to help you

night gull
#

the reason is clearly u being unfriendly to people trying to help u in their free time

crimson spear
tired ingot
#

just wrap your code in a code block as requested

crimson spear
mighty olive
crimson spear
crimson spear
night gull
#

people can block u as they want. especially if they see u being rude to someone else

tired ingot
# crimson spear thats not an answer

it is very much an answer. People here try to help those they can, and help us help them. But in case someone is rude, and just stubbornly refusing helping hands/requests...

mighty olive
#

that's the reason. My choice to block, your choice to respond like that. Things will happen that u do not like

#

also doesnt mean that your blocked that i'm not reading your messeges...

crimson spear
#

can you remove her i want to forcus on my code error please

night gull
#

u asked why they blocked u and they responded

crimson spear
night gull
#

but i get that u want to get back on the problem. so let's do that

night gull
#

please post ur code as formatted text with syntax highlighting
ive explained how to do it here:
#1195379743013482626 message

crimson spear
#

import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a;
  int b;

  // HINT: Choose an appropriate loop and a loop condition
  /* Your code goes here */
  {
     System.out.println(
        "Enter two positive integers, the first smaller than the second.");
     a = in.nextInt();
     System.out.println("First: " + a);
     b = in.nextInt();
     System.out.println("Second: " + b);
  } /* Your code goes here */
  

  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
} @golden bane

#

@night gull import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a;
  int b;

  // HINT: Choose an appropriate loop and a loop condition
  /* Your code goes here */
  {
     System.out.println(
        "Enter two positive integers, the first smaller than the second.");
     a = in.nextInt();
     System.out.println("First: " + a);
     b = in.nextInt();
     System.out.println("Second: " + b);
  } /* Your code goes here */
  

  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
}

night gull
#

nope

#

try again, this time with the backticks

crimson spear
#

how

night gull
#

ive explained how to do it here:
#1195379743013482626 message

#

read it carefully

crimson spear
#

do i use the bot

golden baneBOT
#

Please use this format for posting code:

```java
// Example java program
int value = 5;
System.out.println(value);
```

Which results in:

// Example java program
int value = 5;
System.out.println(value);

For syntax highlighting, you have to add the name of the language after the three backticks, like ```java. Please make sure to use exactly this format, so no space between the backticks and the language name, and a newline before the code starts. If done right, the syntax highlighting will even be applied to your text as you type, before sending.

#

opriate prompt for the user to enter the first number
System.out.print("Enter the first number: ");
a = in.nextInt();

  // HINT: Choose an appropriate prompt for the user to enter the second number
  System.out.print("Enter the second number: ");
  b = in.nextInt();

  // Calculate and print the sum of the two numbers
  int sum = a + b;
  System.out.println("The sum of " + a + " and " + b + " is " + sum);

  // Calculate and print the difference of the two numbers
  int difference = a - b;
  System.out.println("The difference between " + a + " and " + b + " is " + difference);

  // Calculate and print the product of the two numbers
  int product = a * b;
  System.out.println("The product of " + a + " and " + b + " is " + product);

  // Calculate and print the quotient of dividing the first number by the second number
  double quotient = (double) a / b;
  System.out.println("The quotient of dividing " + a + " by " + b + " is " + quotient);

}
}

crimson spear
#

i got it

night gull
#

nope

crimson spear
#

thanks

night gull
#

huh?

crimson spear
#

?

night gull
#

so ur done with the task now?

#

no help needed anymore?

golden baneBOT
#

d: ");
int num1 = input.nextInt();
int num2 = input.nextInt();

     while (num1 >= num2) {
        System.out.println("The first number must be smaller than the second number. Please try again.");
        System.out.println("Enter two positive integers, the first smaller than the second: ");
        num1 = input.nextInt();
        num2 = input.nextInt();
     }
     
     // Rest of the code goes here
  }
night gull
#

im not sure what ur trying to tell me with that

crimson spear
tired ingot
#

please read what the bot says...

crimson spear
#

i was trying the bot out

night gull
#

then please post the code proper

tired ingot
#

it really isn't that hard

night gull
#

please post ur code as formatted text with syntax highlighting
ive explained how to do it here:
#1195379743013482626 message

crimson spear
night gull
#

three backticks, java, newline, code, newline, three backticks

golden ermine
#

Paste your code between three backticks

#

Two blocks of triple backticks

#

And your code between them

mighty olive
#

would the backtick actually be on other language's keyboard ?

tired ingot
#

yes

crimson spear
night gull
#

so please do what it explains

#

```java
code here
```

golden baneBOT
#

Of course! I'll do my best to assist you. Could you please provide more details about the error you are experiencing? Additionally, if you can share the code or the specific error message, it would be helpful in understanding the issue and providing a solution.

crimson spear
#

yes

tired ingot
night gull
#

please stop using the chatgpt command. it won't help u here

#

it only interrupts our conversation

crimson spear
# night gull please stop using the chatgpt command. it won't help u here

import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a = 0;
  int b = 0;

  System.out.println(
        "Enter two positive integers, the first smaller than the second.");
  a = in.nextInt();
  System.out.println("First: " + a);
  b = in.nextInt();
  System.out.println("Second: " + b);

  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
}

tired ingot
#

no

crimson spear
#

๐Ÿ˜ญ

night gull
#

solving ur issue, if u would be cooperative, stick with us and not constantly get sidetracked, would be solved within 5-10mins

night gull
#

now, we are sitting here for a full hour already

#

im out of time. cheers

crimson spear
#

๐Ÿ˜•

golden ermine
crimson spear
golden ermine
#

Why cant u Just answer a question? I want to help you

crimson spear
golden ermine
#

Write this please

#

Write this in a message here

mighty olive
crimson spear
crimson spear
#

?

golden ermine
#

Here

#

Just here

#

Send a message same as mine

crimson spear
#

i wrote the code tho

golden ermine
#

Copy and paste it into your message box on discord

#

Okay

#

You are clearly trolling sorry

#

That's unbelieveable

crimson spear
tired ingot
#

<@&272766283597217802> this is...

golden ermine
#

Do you know how to write a message on discord Channel?

crimson spear
#

why would you say that

#

when i am having problems with this

golden ermine
#

Answer me

crimson spear
#

answer what

golden ermine
#

Do you know how to write a message on discord Channel?

golden ermine
#

So write a message I asked for

tired ingot
#

It's not hard to do:

golden ermine
#

Write this

#

Send a message containing ```java

night gull
#

please remain friendly. if u don't want to help anymore, bc its unpleasant, just leave the discussion or block the user. better than being mad at them. someone else might have the patience to assist. thanks

crimson spear
#

its not letting me paste it

#

java

golden ermine
#

So write it by yourself

#

Three backticks and Word java

#

`

#

This sign

crimson spear
#

i did that

golden ermine
#

Copy this sign

crimson spear
#

it won't let me enter on my computer

#

when i wrote what u said

#

public class TwoNumbers
{
   public static void main(String[] args)
   {
      Scanner in = new Scanner(System.in);

      int a;
      int b;

       do {
         System.out.println("Enter two positive integers, the first smaller than the second.");
         System.out.print("First: ");
         a = in.nextInt();

         // Clear the buffer
         in.nextLine();

         System.out.print("Second: ");
         b = in.nextInt();

         if (a <= 0 || b <= 0 || a >= b) {
            System.out.println("Invalid input. Please try again.");
         }

      } while (a <= 0 || b <= 0 || a >= b);
      

      // This line should only be printed when the input is correct
      System.out.println("You entered " + a + " and " + b);
   }
} ```java
mighty olive
#

asci code = 96

golden ermine
#

Perfect

#

Now listen to me please

crimson spear
#

ok

golden ermine
#

Paste your code below the three ticks and Java Word

#

And below your code paste three ticks Without Java Word

tired ingot
#

do it like what I showed in my image

golden ermine
#

Now add three backticks on the bottom

#

After your code

crimson spear
#

java import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a;
  int b;

   do {
     System.out.println("Enter two positive integers, the first smaller than the second.");
     System.out.print("First: ");
     a = in.nextInt();

     // Clear the buffer
     in.nextLine();

     System.out.print("Second: ");
     b = in.nextInt();

     if (a <= 0 || b <= 0 || a >= b) {
        System.out.println("Invalid input. Please try again.");
     }

  } while (a <= 0 || b <= 0 || a >= b);
  

  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
}

golden ermine
#

Ok sorry, but I cannot help you

crimson spear
#

..

#

<@&272766283597217802>

night gull
crimson spear
#

like what he told me too do

tired ingot
#

do it like in this image please

night gull
#

perhaps we have regained our patience batteries by tomorrow ๐Ÿ™‚

crimson spear
#

i did

#

public class TwoNumbers
{
   public static void main(String[] args)
   {
      Scanner in = new Scanner(System.in);

      int a;
      int b;

       do {
         System.out.println("Enter two positive integers, the first smaller than the second.");
         System.out.print("First: ");
         a = in.nextInt();

         // Clear the buffer
         in.nextLine();

         System.out.print("Second: ");
         b = in.nextInt();

         if (a <= 0 || b <= 0 || a >= b) {
            System.out.println("Invalid input. Please try again.");
         }

      } while (a <= 0 || b <= 0 || a >= b);
      

      // This line should only be printed when the input is correct
      System.out.println("You entered " + a + " and " + b);
   }
} ```java
mighty olive
#

try this ->

crimson spear
#

yeah

mighty olive
#

if u cannot type ` , the shortcut is alt+096

crimson spear
#

public class TwoNumbers
{
   public static void main(String[] args)
   {
      Scanner in = new Scanner(System.in);

      int a;
      int b;

       do {
         System.out.println("Enter two positive integers, the first smaller than the second.");
         System.out.print("First: ");
         a = in.nextInt();

         // Clear the buffer
         in.nextLine();

         System.out.print("Second: ");
         b = in.nextInt();

         if (a <= 0 || b <= 0 || a >= b) {
            System.out.println("Invalid input. Please try again.");
         }

      } while (a <= 0 || b <= 0 || a >= b);
      

      // This line should only be printed when the input is correct
      System.out.println("You entered " + a + " and " + b);
   }
} ```java
golden baneBOT
# crimson spear ```javaimport java.util.Scanner; public class TwoNumbers { public static voi...

Detected code, here are some useful tools:

Formatted code
javaimport java.util.Scanner;
public class TwoNumbers {
  public static void main(String[] args) {
    Scanner in = new Scanner(System.in);
    int a;
    int b;
    do {
      System.out.println("Enter two positive integers, the first smaller than the second.");
      System.out.print("First: ");
      a = in.nextInt();
      // Clear the buffer
      in.nextLine();
      System.out.print("Second: ");
      b = in.nextInt();
      if (a <= 0 || b <= 0 || a >= b) {
        System.out.println("Invalid input. Please try again.");
      }
    }
    while (a <= 0 || b <= 0 || a >= b);
    // This line should only be printed when the input is correct
    System.out.println("You entered " + a + " and " + b);
  }
}
mighty olive
#

if u type the last image as text in here it should appear as code and then all u have to do is insert the proper code

crimson spear
#

yeah it is

#

but i am still getiing errors

mighty olive
#

might i infom what your language is?

crimson spear
mighty olive
#

right , then its not some auto translate problem

mighty olive
#

can u insert your code formatted in the correct way please

crimson spear
#

i understand you

mighty olive
#

like others have said, the issue is resolved in less then a minute if u take the time to paste it properly

crimson spear
#

scroll up

mighty olive
#
test
crimson spear
#

oh i have to put test

#

in the front

mighty olive
#

if u tried the image like i've shown u would have made a code block

#

then all u had to do was replace the test with the actual code

crimson spear
#

so its 3 tiks and test?

golden baneBOT
#

Please use this format for posting code:

```java
// Example java program
int value = 5;
System.out.println(value);
```

Which results in:

// Example java program
int value = 5;
System.out.println(value);

For syntax highlighting, you have to add the name of the language after the three backticks, like ```java. Please make sure to use exactly this format, so no space between the backticks and the language name, and a newline before the code starts. If done right, the syntax highlighting will even be applied to your text as you type, before sending.

mighty olive
#

that ^

crimson spear
#

public class TwoNumbers
{
   public static void main(String[] args)
   {
      Scanner in = new Scanner(System.in);

      int a;
      int b;

      // HINT: Choose an appropriate loop and a loop condition
      /* Your code goes here */
      {
         System.out.println(
            "Enter two positive integers, the first smaller than the second.");
         a = in.nextInt();
         System.out.println("First: " + a);
         b = in.nextInt();
         System.out.println("Second: " + b);
      } /* Your code goes here */
      

      // This line should only be printed when the input is correct
      System.out.println("You entered " + a + " and " + b);
   }
} ```
golden baneBOT
# crimson spear ```javaimport java.util.Scanner; public class TwoNumbers { public static voi...

Detected code, here are some useful tools:

Formatted code
javaimport java.util.Scanner;
public class TwoNumbers {
  public static void main(String[] args) {
    Scanner in = new Scanner(System.in);
    int a;
    int b;
    // HINT: Choose an appropriate loop and a loop condition
    /* Your code goes here */
     {
     System.out.println(
     "Enter two positive integers, the first smaller than the second.");
     a = in.nextInt();
     System.out.println("First: " + a);
     b = in.nextInt();
     System.out.println("Second: " + b);
     } /* Your code goes here */
    // This line should only be printed when the input is correct
    System.out.println("You entered " + a + " and " + b);
  }
}
mighty olive
#

place the import on a new line

crimson spear
#

oh ok

mighty olive
crimson spear
#
      /* Your code goes here */
      {
         System.out.println(
            "Enter two positive integers, the first smaller than the second.");
         a = in.nextInt();
         System.out.println("First: " + a);
         b = in.nextInt();
         System.out.println("Second: " + b);
      } /* Your code goes here */ ```
golden baneBOT
crimson spear
#

๐Ÿ’€

mighty olive
#

almost there

#

try again

crimson spear
#

ok

#
      /* Your code goes here */
      {
         System.out.println(
            "Enter two positive integers, the first smaller than the second.");
         a = in.nextInt();
         System.out.println("First: " + a);
         b = in.nextInt();
         System.out.println("Second: " + b);
      } /* Your code goes here */ ```
golden baneBOT
mighty olive
#

right, before this is getting to silly. Do u see the a and b u declared ?

#
 int a;
int b;
#

those

#

do u see them ?

mighty olive
#

ok, the problem is that u did not initialize them, hence they cannot be used

#

so u need to place a default value in them to be initialized

crimson spear
#

yeah ik

mighty olive
#

that's your problem.

#

it even sais so on the actual error messege, so it's always wise to read those

crimson spear
#

iok

#

import java.util.Scanner;

public class TwoNumbers
{
public static void main(String[] args)
{
Scanner in = new Scanner(System.in);

  int a;
  int b;

 do {
        System.out.println("Enter two positive integers, the first smaller than the second.");
        a = in.nextInt();
        System.out.println("First: " + a);
        b = in.nextInt();
        System.out.println("Second: " + b);
    } while (a >= b);

  // This line should only be printed when the input is correct
  System.out.println("You entered " + a + " and " + b);

}
}

#

<@&272766283597217802>

#

i got one part correct

#

the other 2 are wrong

tired ingot
#

please use code blocks, and don't randomly ping moderators

#

and the testcases also say where the issue lies.

#

you do not have enough validation

night gull
crimson spear
#

i am getting errrors

#

please look above

#

what i sent

night gull
#

yeah, but the moderators are not there for assisting u with ur code issues

night gull
#

they are there for protecting u if someone is rude to u or otherwise conflicts the rules

#

so please dont abuse this ping

#

its like calling the police

crimson spear
#

yeah yeah

night gull
#

in fact, our telephones ring and we rush to the computer when u do that

tired ingot
#

Also this is not a code error, you're literally missing code. You haven't implemented the requested validation. CFR #rules not doing your homework for you.

crimson spear
tired ingot
crimson spear
#

i have seen the rules

tired ingot
#

<@&272766283597217802> this does seem an apt ping?

#

And you were wondering why people blocked you earlier, this seems like a good showcase.. I am trying to help, and point out where the issue lies.

crimson spear
#

its fine pal

mighty olive
#

@tired ingot screenshot fast; things are not written in stone on discord ๐Ÿ˜‰

crimson spear
#

@tired ingot i did nothing to you bro

#

i read the rules ok

#

and i am looking at the code

#

there isn't a problem between us

#

i know i am doing the work on my own

tired ingot
#

eh, he already edited it. He's seemingly just ignoring them if he actually read them. One can only lead a horse to water as the proverb goes.

mighty olive
crimson spear
mighty olive
#

thats not for u

crimson spear
#

you are nosy @mighty olive

#

@night gull help here

crimson spear
open path
#

Why did I got mentionned 4 times ?

tired ingot
#

I think not you specifically, rather your purpleness

mighty olive