<div dir="ltr">On 24 February 2013 22:43, <span dir="ltr"><<a href="mailto:piterrr.dolinski@gmail.com" target="_blank">piterrr.dolinski@gmail.com</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Josh,<br>
<br>
Not thank you for your malicious post.<br></blockquote><div><br></div><div style>Be careful, us programmers do *eventually* catch on to who is a troll, and if you say things like that we may eventually mark you off as just to hostile.</div>
<div style>I *honestly* meant no malice or insult. If you can't take my word, you can point out what I said that was otherwise.</div><div style><br></div><div style>(Then again, you'll have about a week before we really start to notice :P)</div>
<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I think you are missing the point here.<br>
<br>
My source code was just a dummy to offer context for the question I wanted to ask. Further down the line, if I ever feel I don't need to pseudo-declare variables I will stop doing it. But for the moment I am trying to imitate familiar ground.<br>
<br>
My code as written has no syntax errors, so what's the problem? It is highly unlikely you will ever read any of my Python code - no need to get excited over a few of my lines.<br></blockquote><div><br></div><div style>
You said "<span style="font-family:arial,sans-serif;font-size:10px">Any comments on this before I quit my job?".</span></div><div style><span style="font-family:arial,sans-serif;font-size:10px"><br></span></div>
<div style><span style="font-family:arial,sans-serif;font-size:10px">I commented on how I think you should approach Python in order to appreciate its virtues rather than get stuck in its differences. Again, I am no good programmer, but I think these methods will help you.</span></div>
<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
And you don't need to answer questions which were not posed, thank you.<br></blockquote><div><br></div><div style>Nor do I need to answer questions which were posed.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I wanted Python to register what type of variable I'm after. So I init my vars accordingly, int might be 0, float 0.0 and string with null, err... None.<br></blockquote><div><br></div><div style>You seem to think that a "null" version of a type is the falsy version. Then:</div>
<div style>int -> 0</div><div style>float -> 0.</div><div style>tuple -> ()</div><div style>list -> []</div><div style><br></div><div style>And then (*dun dun duuun!*):</div><div style><br></div><div style>str -> "" (NOT None, which is a different type)</div>
<div><br></div><div style>Other people have commented on whether this is a good idea (it's not), so I'll suggest you read those, too.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
In practice, I wouldn't define an intX_asString var, I would do "str (num)" every time a string representation is needed, provided it isn't a loop, as in that context the expression would probably negatively impact performance in an interpreted language.</blockquote>
<div><br></div><div style>PS: Guess what str(None) is.</div></div></div></div>