Computer Science, asked by MFK07, 1 month ago

Write a program of java in blue J to input 2 numbers and a character, if the character is '+' , find and display the sum else display their product.​

Answers

Answered by johandamian776
4

This is the answer:

If d = 0 : both the characters are same.

If d \< 0 : first character is smaller.

If d > 0 : second character is smaller.

Sample Input :

D

P

Sample Output :

d = (68 - 80) = -12

First character is smaller

Answered by ny867847
1

ANSWER

If d = 0 : both the characters are same.

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.If d > 0 : second character is smaller.

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.If d > 0 : second character is smaller.Sample Input :

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.If d > 0 : second character is smaller.Sample Input : D

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.If d > 0 : second character is smaller.Sample Input : D P

If d = 0 : both the characters are same.If d \< 0 : first character is smaller.If d > 0 : second character is smaller.Sample Input : D PSample Output : d = (68 - 80) = -12

d = (68 - 80) = -12First character is smaller

I HOPE IT WILL HELP YOU

Similar questions