2014-11-27 05:57:49

Please tell me the programming language that is easy to learn (not bgt) and write games along with application windows, only for windows. Basic pascal, c ++, c #.

2014-11-27 08:44:07

There is no Basic C++/C/C#/Pascal. owever, you might want to try PureBASIC, which is a wonderful programming language for grame creation and general application development. C++ is meant for those who have mastered computer programming or who want to get deep down under the surface of computing and learn the guts and inner workingsof a computer. C is generally used for operating system development. It is what the UEFI and UEFI Specification use. Pascal programmers... well... I'm not sure what pascal is used for, but one major industry it is used in is teaching programming. There are more than 200 programming languages available, and from this overview of some of them, I am only suggesting to you some very good and popular ones; I am not forcing you to use one.

"On two occasions I have been asked [by members of Parliament!]: 'Pray, Mr. Babbage, if you put into the machine wrong figures, will the right answers come out ?' I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a question."    — Charles Babbage.
My Github

2014-11-28 23:09:37

Woah,

Ok, let me chip in here. smile
You want to write applications for Windows that aren't necessarily games, which as you correctly say rules out BGT.
I will urge you to immediately forget Pascal. Although there are still people that use this language, it is starting to become a nitch language and is falling out of use.
Now you offer up some interesting options, but are missing a few key players. Let me outline your choices first:

Basic

Basic itself is too old to actually work with in this day and age, although there are some variants out there that are made to work on modern operating systems. One of the more popular ones is PureBasic, which has been used , for example, by Ghorthalon. This is a viable option, but not the easiest to start with as a beginner in my opinion because the community for it , although large, isn't nearly as big as more mainstream alternatives. Which brings me neatly to:

c#:
C#, or C-Sharp, is a language which talks to the huge windows library called the .NET framework. Together with Visual Basic .NET, this is one of the biggest languages out there right now for pure Windows application development. It is easy to learn in that it is easy to get a basic application with an actual graphical user interface going from chapter one of every tutorial you will find on the language. Visual Studio, the preferred program to write these applications, has recently become free for everyone, making the entry threshold considerably smaller.

c++:
C++ is a very powerful applications level programming language, however the learning curve is rather steep. I won't discourage you from learning it, but it will not be easy.
Java:
I hesitate to include Java in this list, because to actually write applications in Java that run in the Windows operating system you need to know quite a bit, especially if you want them to be accessible. However, it is sort of c++'s easier big brother and it is very widely used. It is the primary language to write Android applications, for example.

Python:
Python is a very, very readable language, and that is one of its strong points. This makes the learning curve for the language very gentle and it's very easy to get started with it. I recommend this to all beginners of programming.

In closing:
- If you just want to write Windows applications with a user interface quickly and without fuss, .NET languages like c# and visual basic .NET are your best bet.
If you want to know a bit more next to just quickly cobbling windows applications together, I recommend you start with Python.

I hope that helps. Don't hestitate to ask if you have more questions.

Balliol

2014-11-30 19:35:42

My concern about Python is that it encourages some practices that will eat you alive in languages like C# or C++.
Python lets you declare variables without typing them, something which absolutely will not work in a c-style language. You are also allowed to do things like:
a,b = 1,2
This is very, very creative, but again, not gonna happen in most any other language. Then there's the fact that you can index an array like so
array[-1]
I dare you to try that in C++ and see what happens. Atually, I don't think that would be a good idea at all. big_smile I also don't like the way python handles objects, wherein you have to set a variable equal to the constructer of a class. Then there's the way private members are handled, which is clunky and less readable than something like C++...I could go on, but I think you get my point. I know there are certainly many people out there who like Python, and that it is widely accepted as a good programming language, so I'll stop my rant now. big_smile

Best Regards,
Hayden

2014-11-30 19:57:01

The points you are making are good ones, but then again this could be said about all loosely-typed languages. Ruby, JavaScript, just to name a few.
Every language has its good and bad points smile

Balliol

2014-11-30 20:26:05

@4:
I feel this requires some comment, because it brushes a whole set of issues under the rug.
I'm not going to start the argument about variable types and declaration in the way that it needs to be started because the way in which the argument is being phrased means that you're not familiar with the argument, which literally tens of thousands of programmers have had before you.  Very vocally and all over the internet.  Google dynamic vs. static typing if you really want to understand the wider claims, and please realize that both languages have things they are better and worse at.  In the end, it just comes down to preference.  That said, dynamic typing seems to be winning-even C# is starting to support some of those features now, and even C++ has removed the need to specifically declare types.  Most of the dynamic languages with implicit variable declaration will complain if you use something on the rhs of an assignment before using on the lhs, so really the difference here is just that you drop the word int or whatever.  Arguing about it in this manner misses the whole point of the argument, so google the issue if you want to understand it.
Saying that Python/Ruby/whatever has practices that will screw you up in C#/C++/whatever goes both ways.  Because C+/C#/whatever has practices that will screw you up in Python/Ruby/etc, too-I'm thinking of method overloading, modules as code that you cut/paste into another file, being stuck in the mindset of types rather than capabilities.  Since every good programmer I'm aware of is a polyglot, that is knows multiple languages usually of different programing paradigms, this ends up not being an issue save for the newest programmers.
As for "cleverness", well, yeah.  And C# has Linq, C++ has first-class function objects that beat even Python and very strict guarantees on exactly when and how objects will be cleaned up (try automatically freeing resources in a garbage collected language, and be very frustrated by the lack of such guarantees).  You can find "cleverness" in almost every language of one sort or another; the only counterexample I can think of offhand is java, but even there people abuse some pretty esoteric features to achieve some pretty basic things that the language doesn't provide for.  I fail to see what's wrong with cleverness applied properly, and I can write both of your examples for Python in C++, all be it with some variable declarations.  The [] operator can be overloaded to provide the negative index functionality in a Pythonic std::vector variant, probably just inheriting from std::vector and overriding one function, and C++11 gives us std::tuple and std::tie, which achieve the same semantics as your tuple unpacking, though I doubt you know it by that name.  Also, no one uses a,b=1,2 in practice, at least not that I've seen-that feature is meant for and usually used for something unrelated.
And finally, you seem to be not understanding Python fully.  Private is not part of the Python vocabulary.  If it starts with _, the convention is that you don't use it in your code.  But this is a convention.  And I have no idea what you mean by assigning constructors to a variable-they're specially named functions, like in every other language, and you do your initialization in them, again like every other language.
I'm just going to close with this.  Python is about assuming that the programmer using it is trustworthy and adult enough to know that touching private things is bad and assuming that programmers can write good programs when given extra capabilities.  C++ is about assuming that you want performance, and the entire language falls out from this, including it's most esoteric features and extreme levels of complexity (if you disagree with this last bit, you do not know C++; Google variatic templates, move constructors...).  java is about assuming that you are a bad programmer, and consequently giving you absolutely one way to do everything, so that even bad programmers can work on a team.  This comes at the cost of good programmers liking it, and drops productivity for people who are used to list comprehensions and the like.  C# is about locking you to the Microsoft stack as much as possible, and borrows a lot of philosophy from java.  I'm not claiming that you should go like Python now, but I think it is important to distinguish between things you dislike about Python and things that are actually objectively harmful programming practices.

My Blog
Twitter: @ajhicks1992

2014-11-30 20:38:48

I was pressed for time when responding to 4, but Camlorn just said everything I was thinking in much better terms than I ever could.
Thanks wink

Balliol

2014-12-01 04:54:55

Hi,
Camlorn: Most everything you said made sense, except for this last bit:
"And finally, you seem to be not understanding Python fully.  Private is not part of the Python vocabulary.  If it starts with _, the convention is that you don't use it in your code.  But this is a convention.  And I have no idea what you mean by assigning constructors to a variable-they're specially named functions, like in every other language, and you do your initialization in them, again like every other language."
To the issue of  private members: I would've assumed you were familiar with the fact that you can indeed give a class such members in python, by proceeding with a double underscore. After doing this, you must refer to these members in the same way, and in no way, shape or form can they be accessed outside of their class directly. That said, I'm baffled as to how you can call that a "convention" as opposed to a language feature.
For your second point: I'm not precisely sure what in particular you are driving at here. My issue with the way objects are declared stems from the ambiguity of such an assignment. If I do not know that there is a class of that name, the assignment might just look like a function call--there is no particularl way to be sure of the return type for such a function. IN a C-style language, I know that I am creating an instance of a class because I see that there is a type prefacing the name--such a type must be either a struct or class of some sort if it is not a built-in type.

Best Regards,
Hayden

2014-12-01 06:09:47

I'd drop this point because it's off topic, but I think these comments are valuable to others.  Nevertheless, I do not plan to entertain it much past this post.
Yes, technically you can use the double underscore.  I have not once ever seen any real code do this.  It is not in the Python philosophy even if it is in the Python language, and you really have to go digging to even find that particular feature mentioned these days.  If I said private, everyone I know would assume the single underscore convention.  Do I know about the magic double underscore?  yes.  Do I know the specific rules governing it without looking them up? No, nor does anyone I know.  It's outside the philosophy that Python encourages, and you don't need the name mangling often, if at all.  I can honestly say that I have never used it nor heard it mentioned of as a serious solution to a problem once.  I could see a case for it, but only really in classes you're specifically intending for users of a library you're writing to inherit from.  Any other good Python programmer will respect the single underscore convention, the double underscore "magic" doesn't actually make anything private, and I must congratulate you on managing to bring what is maybe the most obscure feature of Python I'm aware of into the conversation.  This is beyond even the operator overloading special methods and the wonderful corner cases of the garbage collector, and the only other contender for things I'd not expect the other Python programmers I interact with on a regular basis to know offhand is how Numpy and Scipy implement their special slicing syntax (which your code can do, too).
The way you worded your statement about constructors was confusing given that you can assign functions to variables in literally every programming language I know of.  I assumed you meant something like:

my_constructor = MyClass.__init__

Though kind of useless, given that this would actually circumvent __new__ and some other parts of the Python class creation process when you called your new my_constructor function, this is quite legal.  More interestingly, you may assign values to functions in Python.  It is worth noting that this type of thing is how many NVDA add-ons do stuff.  You could reverse the above statement, if you wanted; I advise against this highly, but you can.
As for how you tel, you tell by following the PEP8 style guides, which is the default for most new Python projects.  Function and variable names are lower case with words separated by underscores, classes are camelcase with first letter capitalized.  If you don't like those, you can make up your own; many other Python programmers will frown at this, however, as Python is one of the few languages that actually has something adopted somewhat globally.  My one concession is that I use one tab instead of four spaces.  Before shrugging at style, take it from me and--again--tens of thousands of others that you need it even in languages with more rigid syntax.
It's clear enough that you have a function that is returning a value, in any event, and there's really not much difference between that and a constructor.  Python is not a language in which constructors have any special magic powers; they are almost exactly equivalent to a function returning a new object that lives outside the object in question.  Why then should they be given special syntax?  In all honesty, not even C++ gives constructors too many magic powers, though it is true they have at least a few there.  Nevertheless, this viewpoint still holds.  I do know that some languages make the syntax special in all cases and disallow constructor calls in expressions, but I fail to see the actual difference semantically and, in many cases, I could generalize it by making a createMyType function or renaming all my classes _myclass and making a MyClass function.
What you are saying is that you don't like Python.  That's fine, there's plenty of others.  Either you're a new programmer and still need the crutch of very specific syntax, or you've chosen the static typing side of the typing war and the compilers are god side of the compilers vs. interpreters war.  I am the last person to say that Python is the one true way: I use C++ almost every day and am very seriously looking at Node.js.  But it seems to me that you are looking at the syntax of your language, going "oo, special syntax, that must mean the operation is special", and failing to generalize.  In this specific case and given our discourse here, I would say there is real value for you in picking a project and doing it in Python, trying to be as "Pythonic" as possible in the process.  This isn't about trying to get you to like Python, it's because I think you're not aware of the philosophy of such languages and what they bring to the table, and I think you're at a point where learning about such would benefit you.  The complaints you are making about Python are not even on my valid reasons to choose a language list, and I can say with some certainty that their importance to you will be lessened as you continue programming.  That is, Unless you're one of the very few programmers who specialized on one language over a long period, worshiping it like a religion (these exist, they get paid very big bucks in some cases, and they're not necessarily bad).  But I do not think this is the case.

My Blog
Twitter: @ajhicks1992