User talk:Btx40

From Wikipedia, the free encyclopedia

Welcome!

Hello, Btx40, and welcome to Wikipedia! Thank you for your contributions. I hope you like the place and decide to stay. Here are some pages that you might find helpful:

I hope you enjoy editing here and being a Wikipedian! Please sign your messages on discussion pages using four tildes (~~~~); this will automatically insert your username and the date. If you need help, check out Wikipedia:Questions, ask me on my talk page, or ask your question on this page and then place {{helpme}} before the question. Again, welcome! RJFJR (talk) 14:29, 9 April 2008 (UTC)

[edit] Your message on my talk page

...deleting or editing legitimate comments, as you did at Talk:Comparison of programming languages (basic instructions), is considered as a bad practice, ...

I did what?! You asked for

Any suggestions for other languages or features...

and you got mine. I don't see any bad practice in doing this on the talk page. I'm sorry that I did not properly sign my edit back than. Thanks! Ghettoblaster (talk) 16:08, 16 April 2008 (UTC)

I appreciate your contributions, but I expected it in the form of a reply, not as an edit to my original comment. As I said, I don't know a lot about PowerShell, so anything I contribute is probably incorrect. As for Python, that has been done.
I'm still new here (maybe I should go easy on the warnings) --Btx40 (talk) 16:23, 16 April 2008 (UTC)

[edit] C++ example with std::string

Hi there. The change to use string on the C++ entry was understandable but would fail in practice for a number of reasons. A correct version is below, and maybe the section in ?: should be updated accordingly to provide a full C++ example for novice readers, although learning when not to use STL is an important lesson too.

#include <string>
#include <iostream>
#include <fstream>
 
using namespace std;
 
int main(int argc, char** argv)
{
    string name;
    ofstream fout;
 
    if (argc > 1)
    {
        name = argv[1];
        fout.open(name.c_str(), ios::out | ios::app);
    }
 
    ostream& sout = (name.empty() ? cout : fout);
}
I guess that would be ok - I saw std::string used in teaching C++. I forgot about the #include and didn't really think about empty().
Maybe I should stick to C#. --Btx40 (talk) 19:17, 17 April 2008 (UTC)
C++ is enjoyable when you get friends with it :) but so are many languages and they all have their pros and cons. STL has its problems though and is poorly designed in some respects. Programs using STL container classes can suffer from serious code bloat, and while rich from a mathematical functional perspective, it has some poorly named methods (such as the empty() method) and lacks common functions that developers actually need to use; for me it's always had the feel of being designed by mathematicians rather than real world programmers, although I put that aside these days, live with the flaws and use it heavily.
Moggie2002 (talk) 19:37, 17 April 2008 (UTC)

[edit] C's lack of a true string datatype

Why is it that C does not have a string datatype? This is one of the most short-sighted omissions that I am aware of. --Btx40 (talk) 17:58, 25 April 2008 (UTC)