Write an expression that evaluates to true if the value of the string variable s1 is greater than the value of string variable s2. write an expression that evaluates to true if the value of the string variable s1 is greater than the value of string variable s2.

Respuesta :

It is not entirely clear what this question means. I am going to assume that 'value' of a string refers to a numerical value, i.e. the strings represent numbers. The question also does not mention the programming language to use. There is a function in Delphi:

function isGreater(number1, number2: string): boolean;
begin
     Return StrToFloat(number1)>StrToFloat(number2);
end;


ACCESS MORE
EDU ACCESS