Take two string from user and print 1 if the first string is greater than string 2 and 0 if both equal and -1 if the second is greater than 1. In java

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter2: Using Data
Section: Chapter Questions
Problem 15PE
icon
Related questions
Question
Take two string from user and print 1 if the
fırst string is greater than string 2 and 0 if
both equal and -1 if the second is greater
than 1.
In java
Transcribed Image Text:Take two string from user and print 1 if the fırst string is greater than string 2 and 0 if both equal and -1 if the second is greater than 1. In java
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT