string upperLower(string input)

// This function takes an string as input and returns an upperlower
// version of the same string.
// Example: thisisatest -> ThIsIsAtEsT

{
  string returnstring = "";
  for(int i=0;i<input.size();i++) 
    {
      char nextchar;
      if (i%2==0) {
	nextchar = toupper(input[i]);
      } else {
	nextchar = tolower(input[i]);
      }
      returnstring = returnstring + nextchar;
    }
  return returnstring;
}
