using System;
using System.IO;
public class binaryFileToUpper
{
public static void Main()
{
BinaryReader inFile = new BinaryReader(
File.Open("example.exe", FileMode.Open));
BinaryWriter outFile = new BinaryWriter(
File.Open("example.exe.upper", FileMode.Create));
long filesize = inFile.BaseStream.Length;
for (long i = 0; i < filesize; i++)
{
byte b = inFile.ReadByte();
if ((b >= Convert.ToByte('a')) &&
(b <= Convert.ToByte('z')))
b -= 32;
outFile.Write(b);
}
inFile.Close();
outFile.Close();
}
}