Difference between revisions of "Talk:TADM2E 3.26"

From Algorithm Wiki
Jump to: navigation, search
(Created page with "Algorithm: 1.Write generic method to reverse an array character array. 2. Reverse entire string. So "My name is Chris" becomes "sirhC si eman yM". Lets call it reverseString...")
 
 
Line 1: Line 1:
Algorithm:
+
<nowiki>Algorithm:
  
 
1.Write generic method to reverse an array character array.
 
1.Write generic method to reverse an array character array.
 
2. Reverse entire string. So "My name is Chris" becomes "sirhC si eman yM". Lets call it reverseString
 
2. Reverse entire string. So "My name is Chris" becomes "sirhC si eman yM". Lets call it reverseString
 
3. Reverse each word inside reverseString using generic method but use spaces as delimiters. so "sirhC si eman yM" is reversed 4 times part by part delimited by space and becomes "Chris is name My".
 
3. Reverse each word inside reverseString using generic method but use spaces as delimiters. so "sirhC si eman yM" is reversed 4 times part by part delimited by space and becomes "Chris is name My".
 +
</nowiki>

Latest revision as of 05:40, 23 April 2015

Algorithm: 1.Write generic method to reverse an array character array. 2. Reverse entire string. So "My name is Chris" becomes "sirhC si eman yM". Lets call it reverseString 3. Reverse each word inside reverseString using generic method but use spaces as delimiters. so "sirhC si eman yM" is reversed 4 times part by part delimited by space and becomes "Chris is name My".