/*
 * Description: Remap zero-based special Finnish chars
 *              to upper case equivalents
 * Usage: mapascii
 * Copyright: Daniel Tisza, 2010
 * All rights reserved
 */

#include <stdio.h>
#include <stdlib.h>

int main(int argc, char* argv[])
{
  int c;

  if (argc != 1) /* validate argument count */
  {
    return 0;
  }
  
  while ( (c = getchar()) != EOF) /* for all input characters */
  {
    if (c == 0x5B) /* capital a with ball */
    {
      c = 0xC5;
    }
    else if (c == 0x5C) /* capital a with double dots */
    {
      c = 0xC4;
    }
    else if (c == 0x5D) /* capital o with double dots */
    {
      c = 0xD6;
    }

    printf("%c", c);
  }
}

