Well from the looks of it - I'm late. :/
I won't get started on using gets()/getch()/conio, or the rather blasphemous statement of conio being a standard.
I won't get started on C being the almighty language of the Gods.
I wont get started on whether C's syntax is similar to Python...wait what?! Ok I just might...
Krow Vote Calc Source
PHP:
vote_count = {}
while page_index < page_count:
url = root_url[:-5]
if page_index > 0:
url += '-'+str(page_index+1)
url += '.html'
page_index += 1
print url
response = urllib2.urlopen(url)
page = response.read()
response.close()
parsed_page = BeautifulSoup(page)
pat = re.compile("^post_message_.*")
page_count_txt = ''.join(parsed_page.find('div', attrs={'class': 'pagenav'}).find('td', attrs={'class': 'vbmenu_control'}).findAll(text=True));
page_count = int(page_count_txt[len(page_count_txt)-page_count_txt[::-1].index(' '):])
result=parsed_page.findAll('div', attrs={'id': pat})[1:]
// Omitted for brevity
Now, does that look even remotely similar to C? (Please don't answer that -it's rhetorical)
I mean, sure, you can
print 'Hello Python' and
prinf('Hello C') and claim presto! They're roughly the same, while not even considering that C is a strongly typed language while Python is duck typed. Sheesh. If you still consider the syntax of both the languages is same, Ronaldo here wants to have a word with you:
*3.bp.blogspot.com/-HfgcRU7iVF4/TqLq3nHIwPI/AAAAAAAA-WM/fJe6pvuqaUI/s400/c%2Bronaldo%2Bfunny%2B%25281%2529.jpg
Well, know what I lied. I'm gonna pick up on speed now. You say C is fast - Really? You don't say. What gave it away? The fact that it is closer to ASM constructs or the fact that it's compiled? You don't need a fvking review/benchmark to know that C is faster than Python. Ok, I'll use your figures,
Clearly the syntax is not so different and C is ~23x faster than python. ~3 seconds to do things that can be done in python in ~50 seconds
When you finish your cookie, you might realize that you missed one thing - the programmer's plight. Confused? Lemme rephrase.
Clearly the syntax is very different and writing programs in C is ~23x harder than in python. ~50 seconds to do things that are done in python in ~3 seconds
I'd say, that sums it up. Sure C's faster but at an expense. You take more time to write programs in C than in Python. Same goes for debugging them too.
I'll admit I have a soft spot for C++ as it was the very first language I learnt, but the truth be told I no longer develop in it unless it absolutely calls for the very low level tasks (Low Level Hooks and stuff). When it's only a matter of learning logic, algorithms and getting accustomed to constucts - Python is easier than C/C++. Sure, anyone should then jump to C++ to experience what it is (a different beast in totality), but terming other languages as slow/bad/crap just goes to show the intellect of an individual. I'd quote it again (I happen to quote this a lot - oddly enough it fails to register on people)
There are no good or bad languages but the right tools for the right job.