Hi,
you can either use print instead of printf
print "<table width=\"100%\">";
or with printf:
printf("<table width=\"100%s\">","%");
which makes no sense here. printf is used to print data formatted. % is a reserved character in this case. Read the manual about print and printf and you'll see when to use which one of those functions 🙂
In either case you don't have to escape %.