99 Bottles of Beer - Obfuscated
Believe it or not, the following JSP code perfectly reproduces the "99 Bottles of Beer on the Wall" song, I entered this code onto the 99 Bottles of Beer website, and it is still awaiting submission. However, you can grab a copy of this code right now. This code is far from completely obfuscated, as it doesn't take a lot of figuring out, to work out how it works, but it is an example of making things harder for people to do.
<%String b[]={" bottle"," beer","<br>"," on the wall","no more","Take one down pass it around, "};
int x=99;while(x>0){int l=2;while (l>0){%>
<%=x%><%=b[0]%><%=x!=1?"s":""%> of <%=b[1]%><%=l--==2?b[3]+", ":b[2]%><%}%>
<%=b[5]%><%=--x>0?x+b[0]:b[4]+" "+b[0]%><%=x!=1?"s ":" "%>of<%=b[1]%><%=b[3]%>.
<%=b[2]%><%=b[2]%><%}%>
<%=b[4].substring(0,1).toUpperCase()+b[4].substring(1)%><%=b[0]%>s of<%=b[1]%><%=b[3]%>,
<%=b[4]%><%=b[0]%>s of<%=b[1]%><%=b[2]%>
Go to the store, buy some more, 99<%=b[0]%>s of<%=b[1]%><%=b[3]%>.<%=b[2]%>






