Domanda di colloquio di Qualcomm

Reverse a string

Risposte di colloquio

Anonimo

27 dic 2014

Solution in python: x = "String to be reversed" n = "" for m in range(len(x)): n = n + x[len(x) - m - 1]

2

Anonimo

14 dic 2014

Apache Commons lang: StringUtils.reverse("String to be reversed");

1

Anonimo

23 mag 2015

void reverseString(char *str){ char * end; char temp; if(str){ while(*end){ ++end; } end--; while(str

1

Anonimo

17 gen 2018

string[::-1]