C
C#2y ago
asianaf

✅ Trying to display a string backwards and lower case

And I don't understand on how to use Reverse() method
5 Replies
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
MODiX
MODiX2y ago
tebeco#0205
REPL Result: Success
public static string Reverse( string s )
{
char[] charArray = s.ToCharArray();
Array.Reverse(charArray);
return new string(charArray);
}

Reverse("Jack Black")
public static string Reverse( string s )
{
char[] charArray = s.ToCharArray();
Array.Reverse(charArray);
return new string(charArray);
}

Reverse("Jack Black")
Result: string
kcalB kcaJ
kcalB kcaJ
Quoted by
<@!689473681302224947> from #help-0 (click here)
Compile: 555.860ms | Execution: 31.240ms | React with ❌ to remove this embed.
Accord
Accord2y ago
Closed!
asianaf
asianaf2y ago
@tebeco quick question am I able to use a Length property to reverse or no
Accord
Accord2y ago
Closed!
Want results from more Discord servers?
Add your server