<myBlog show="last" ⁄>
<mySnippets order="rand" ⁄>
<myPhoto order="random" ⁄>
<mySnippets type="lang" ⁄>
<myQuote order="random" ⁄>
<myContacts ⁄><email ⁄>
<windows live messenger ⁄>
<myCurriculum type="pdf" ⁄>
<myVisitorsMap ⁄>Scripting languages are all about getting code up and running as fast as possible. In that spirit, many scripting languages permit, or even require, implicit variable declarations.
If you want a variable named "PhaseInverterCount", you do this:
PhaseInverterCount = 1
and bam! you have a variable named PhaseInverterCount. What could possibly go wrong?...
Fat Fingers
The trouble starts when you do something like this:
PhaseInverterFound = nil
foreach starship in Starships do
if starship.IsPhaseInverted() then
PhaseInvertedFound = starship
break
end
end
Everything looks good. You run your script, don't get any warnings or errors, but you find that the code never seems to locate that one starship in your fleet that has a phase inverter. Why?
The first time you typed PhaseInverterFound, but inside the conditional you accidently typed PhaseInvertedFound. How long will it take you to find this typo?
este é só um excerto do artigo, para aceder ao artigo completo, clique no link em baixo:
this is just a small excerpt from the article, to access the full article please click in the link below:
http://hexagog.com/blog/how-your-scripting-language-works-against-you/
<myNews show="rand" cat="programacao" ⁄>