#!/usr/bin/env python
from base64 import *
from sys import *

try:
  while (True):
    print (b64encode(stdin.next()))
except StopIteration, e:
  pass
