a) Write an integer function Input as follows:
function Input(s)
The function takes in a String parameter that will be used as part of the input prompt, e.g. "Please enter 1st integer" and "Please enter 2nd integer". It returns an integer value corresponding to the user input.
b) Write a function bigger that takes in 2 integer values first and second. It compares which number is bigger and returns one of the following string values:
"1st number is bigger"
"2nd number is bigger"
"The 2 numbers are equal"
c) In the main part of the program, invoke Input(“1st”) and Input(“2nd”) to get the values of first and second. Invoke bigger and display the string returned.
Я столкнулся с некоторой проблемой с моим кодом, поскольку он, кажется, не работает, так как я не знаю, как связать входы вместе. Это один из моих практических вопросов.
Я пытался связать входные данные вместе, но я не уверен, как это сделать, потому что вопрос немного сбивает с толку.
Я не знаю, как описать свою проблему, так как не совсем понимаю требования к вопросу