import java.util.ArrayList; import java.util.List; import java.util.Scanner;
public class Main {
public static void main(String[] args) {
List<String> list = new ArrayList<>();
Scanner sc = new Scanner(System.in);
while (sc.hasNext()){
String str = sc.nextLine();
if("".equals(str)){
return;
}
int quotient = str.length()/8;
int remain = str.length() % 8;
//添加0的个数
int addZero;
if(remain==0){
addZero = 0;
}else {
addZero = 8 - remain;
}
if(str.length() > 8) {
for (int i = 0; i < quotient; i++) {
String newStr = str.substring(i * 8, (i + 1) * 8);
list.add(newStr);
}
if(addZero != 0) {
String newStr = str.substring(quotient*8,(quotient*8+remain));
for (int i = 0; i < addZero; i++) {
newStr = newStr+0;
}
list.add(newStr);
}
}else {
for (int i = 0; i < addZero; i++) {
str = str+0;
}
list.add(str);
}
}
for (String s : list){
System.out.println(s);
}
}
}