0

How to find reverse of a substring

9th Aug 2017, 3:25 PM
Sarthak Rastogi
6 ответов
+ 1
depends on the language you want to use
9th Aug 2017, 3:33 PM
Martin Ed
Martin Ed - avatar
0
for python: 'hello world'[::-1]
9th Aug 2017, 4:20 PM
Martin Ed
Martin Ed - avatar
0
what about java
9th Aug 2017, 4:40 PM
Sarthak Rastogi
0
new StringBuilder("Hello world").reverse().toString()
9th Aug 2017, 4:46 PM
Martin Ed
Martin Ed - avatar
0
or PHP: string strrev ( string $string )
9th Aug 2017, 4:48 PM
Martin Ed
Martin Ed - avatar
0
finally ruby: $ a = "abc" $ a.reverse!
9th Aug 2017, 4:50 PM
Martin Ed
Martin Ed - avatar