|
I dunno. I wouldn't be surprised if a larger percentage of great programmers were self-taught. Shows initiative/care for the topic.
Posted from SPARTA!!!!!!!!!! 2.0.
Don't forget to rate my post if it helped!
|
|
|
|
|
If you don't ever learn a little something on your own, you'll never be a great programmer.
|
|
|
|
|
Yeah, still can't get over the copypasta 'programmers'.
Posted from SPARTA!!!!!!!!!! 2.0.
Don't forget to rate my post if it helped!
|
|
|
|
|
'copypasta'. That probably where the term spaghetti code comes from.
Ego non sum semper iustus tamen Ego sum nunquam nefas!
|
|
|
|
|
dawmail333 wrote: I wonder what proportion of successful programmers are self-taught? Just a hunch...
Give me a self taught programmer any day.
I've taught programming at both under-grad and post-grad level, and you can tell by the end of the first class who can be good programmers and who will never quite get it.
It's not about brains, although that makes it easier for some.
It's about whether or not you are actually interested.
Learning to be a programmer has much more in common with something like learning to play guitar than with something like being an administrator or a manager.
Anyone can learn the chords, but to go to the next level you have to have the desire/compulsion to pick up the guitar on evening and weekends just because you enjoy it. And the dedication to pick up the guitar to learn something new even when you don't enjoy it.
-Rd
|
|
|
|
|
dawmail333 wrote: I wonder what proportion of successful programmers are self-taught?
Moi.
Marc
|
|
|
|
|
You know him too???
|
|
|
|
|
That's basically the same thing as VB code that uses ON ERROR RESUME NEXT... *shudder*
Reminds me of a story I heard. This college student asked the instructor why his code didn't pass. As in, he got a failing grade. "But there aren't any errors! It compiles!", he argued! Well, it turned out that he'd commented out every line that caused a compilation error, and this cascaded into him commenting out EVERY LINE of his "code" which wasn't any good anyway. Since it didn't create a compilation error, he figured it was correct and submitted it without TESTING it.
I've seen similar things happen in production code, though... mostly from managerial types who learned a little VB in the 90's and bought a couple custom controls and wrote a quick little hacky tool that worked for them and suddenly other people wanted a copy... then years later it's the standard tool for the company... and ugliness happened when some poor shmuck like myself had to add functionality, fix a bug or port it to a web interface
|
|
|
|
|
I hope it was just the TV he ran to.
Cheers,
विक्रम (Got my troika of CCCs!)
After all is said and done, much is said and little is done.
|
|
|
|
|
|
If you find this funny, you'll love <a href="http://thedailywtf.com/">TheDailyWTF.com</a>[<a href="http://thedailywtf.com/" target="_blank" title="New Window">^</a>]
|
|
|
|
|
This is what I would be used to seeing...
if (lang == "Japanese")
{
msg.BodyEncoding = System.Text.Encoding.UTF8;
msg.SubjectEncoding = System.Text.Encoding.UTF8;
}
else if( lang != "Japanese" )
{
msg.BodyEncoding = System.Text.Encoding.UTF8;
msg.SubjectEncoding = System.Text.Encoding.UTF8;
}
|
|
|
|
|
you forgot the fallback, when all other tests failed:
...
else
{
msg.BodyEncoding = System.Text.Encoding.UTF8;
msg.SubjectEncoding = System.Text.Encoding.UTF8;
}
|
|
|
|
|
Don't repeat yourself...
retry:
if (lang == "Japanese")
{
msg.BodyEncoding = System.Text.Encoding.UTF8;
msg.SubjectEncoding = System.Text.Encoding.UTF8;
}
else if( lang != "Japanese" )
{
lang = "Japanese" ;
goto retry ;
}
(Or something like that; I don't actually know how to do a goto...)
|
|
|
|
|
That's OK - you don't need a GOTO!
while (lang != "Japanese")
lang = "Japanese";
....
Software rusts. Simon Stephenson, ca 1994.
|
|
|
|
|
My current workplace, I saw 2 functions, exactly the same except the name, written by a senior developer, who suppose to overlook the juniors!
Mistake?
Well, those two functions are one after the other, both fit right into one screen [that small the functions are].
|
|
|
|
|
//Updated
Hello everyone
I just want to know cost of
Assignment statement
Isok = false;
and if condition
if(Isok == true)
Isok=false;
Thanks
First One
bool IsOk=false;
while(i < 1000)
{
………….
…………
………….
if(i< 100)
{
IsOk=false;
}
i++;
}
Second
bool IsOk=false;
while(i < 1000)
{
………….
…………
………….
if(IsOk && i< 100)
{
IsOk=false;
}
i++;
}
Life's Like a mirror. Smile at it & it smiles back at you.- P Pilgrim
So Smile Please
modified on Monday, September 27, 2010 4:58 AM
|
|
|
|
|
|
I don't see why you would want/need to check it is True just to set it to false. So i would go with the first option.
Dave
Find Me On: Web| Facebook| Twitter| LinkedIn
CPRepWatcher now available as Packaged Chrome Extension, visit my articles for link.
|
|
|
|
|
Maybe it involves a costly network or database transaction?
|
|
|
|
|
yes you got it
so what will you prefere?
Life's Like a mirror. Smile at it & it smiles back at you.- P Pilgrim
So Smile Please
|
|
|
|
|
Even if it does involve an expensive operation, with the code structure we can see, i still cannot see how it makes a difference.
If the code before the 'if' checks the isOk to perform the operation then maybe, but if isOK is already true, and you need to set it back to false if i<100, then maybe the whole way the operation is being done need to be reviewed.
If your logic requires for the the operation to continue until i > 100, then it doesn't matter what happens with isOK, or if it is true already. just set it back to false and get on with what you need to do.
I am maybe not explaining very well what i'm trying to say, but i hope you catch my drift.
Dave
Find Me On: Web| Facebook| Twitter| LinkedIn
CPRepWatcher now available as Packaged Chrome Extension, visit my articles for link.
|
|
|
|
|
They both suck.
Isok seems to be handling two conditions. The one hidden in the comments, that could change it. And the less than 100. That's confusing.
In any case You don't need an if.
Isok = I < 100
Would work.
Sorry for caps and formatting, I'm on a phone.
Rd
|
|
|
|
|
At the moment I'm more concerened with the meaning of while(int i=0) . Will it compile? Will it execute the loop?
|
|
|
|
|
PIEBALDconsult wrote: Will it compile? Will it execute the loop?
Yes. No.
|
|
|
|