Skip to content

Instantly share code, notes, and snippets.

Created July 12, 2017 13:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/b9937bf15fb4fa9177c1b73c528a44f9 to your computer and use it in GitHub Desktop.
Save anonymous/b9937bf15fb4fa9177c1b73c528a44f9 to your computer and use it in GitHub Desktop.
TryCF Gist
<cfscript>
writeOutput("<h2>Test isBoolean() with 3 characters and not isNumeric()</h2>");
start_time = getTickCount();
//error numbers
idx_error = 0;
//ascii-table with 3 chars
for(i=0; i lte 255; i=i+1) {
for(j=0; j lte 255; j=j+1) {
for(k=0; k lte 255; k=k+1) {
str = chr(i) & chr(j) & chr(k);
if (isBoolean(str) and not isNumeric(str)) {
idx_error++;
writeOutput("<br>#idx_error#) string value=""#str#"" - chr(#i#) & chr(#j#) & chr(#k#)");
}
}
}
}
end_time = getTickCount();
writeOutput("<p>Execution time: #end_time-start_time# ms</p>");
</cfscript>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment