Tagged Questions
23
votes
6answers
2k views
How do you encode Algebraic Data Types in a C#- or Java-like language?
There are some problems which are easily solved by Algebraic Data Types, for example a List type can be very succinctly expressed as:
data ConsList a = Empty | ConsCell a (ConsList a)
consmap f ...
49
votes
12answers
5k views
Did the developers of Java consciously abandon RAII?
As a long-time C# programmer, I have recently come to learn more about the advantages of Resource Acquisition Is Initialization (RAII). In particular, I have discovered that the C# idiom:
using (var ...
46
votes
11answers
50k views
For what reasons should I choose C# over Java and C++?
C# seems to be popular these days. I heard that syntactically it is almost the same as Java. Java and C++ have existed for a longer time. For what reasons should I choose C# over Java and C++?
41
votes
8answers
4k views
Why a static main method in Java and C#, rather than a constructor?
I’m Looking for a definitive answer from a primary or secondary source for why (notably) Java and C# decided to have a static method as their entry point, rather than representing an application ...
80
votes
11answers
20k views
What backs up the claim that C++ can be faster than a JVM or CLR with JIT? [closed]
A reoccurring theme on SE I've noticed in many questions is the ongoing argument that C++ is faster and/or more efficient than higher level languages like Java. The counter-argument is that modern JVM ...
69
votes
16answers
9k views
Do the young minds need to learn the pointer concepts?
Why did the C master Dennis Ritchie introduce pointers in C? And why did the other programming languages like VB.NET or Java or C# eliminate them? I have found some points in Google, and I want to ...
19
votes
12answers
2k views
How to teach Exception Handling for New Programmers?
How do you go about teaching Exception Handling to Programmers. All other things are taught easily - Data Structures, ASP.NET, WinForms, WPF, WCF - you name it, everything can be taught easily.
With ...
14
votes
10answers
6k views
Should we choose Java over C# for a new project? [duplicate]
We have a team of .NET developers (C#) with a range of experience from 2 to 6 years. Over the last few years we have been developing Silverlight, ASP.NET MVC, and WPF applications. However, there is a ...
10
votes
2answers
697 views
How can I use my coding skills for good?
By this autumn my two small websites should be generating around a total of $1200 a month with minimal/zero input which is enough to for me to live on comfortably enough.
Rather than embark on ...
27
votes
3answers
1k views
What are the benefits and disadvantages in the approaches of C#, Java and Scala to Closures/Lambdas/…?
I wonder what the technical implementation differences between C# and Scala are and how both solutions compare to the implementation ideas and concerns voiced in the email Peek Past lambda by Brian ...
1
vote
4answers
298 views
Should I continue learning a language if in the meanwhile I became interested in another language/platform? [closed]
I started learning Java a couple of months ago. I also wanted to become more exposed to linux so I installed ubuntu and started working with Java since then. In the meanwhile however I became more ...
62
votes
16answers
6k views
How much freedom should a programmer have in choosing a language and framework?
I started working at a company that is primarily C# oriented. We have a few people who like Java and JRuby, but a majority of programmers here like C#. I was hired because I have a lot of experience ...
46
votes
11answers
3k views
I don't understand how TDD helps me get a good design if I need a design to start testing it
I'm trying to wrap my head around TDD, specifically the development part. I've looked at some books, but the ones I found mainly tackle the testing part - the History of NUnit, why testing is good, ...
31
votes
11answers
15k views
Java vs. C# - Productivity perspective [closed]
If you have a number of years experience in working with Java and a number of years experience in working with C# and .NET, I would value your opinion on software development productivity differences ...
36
votes
6answers
6k views
Good example of complex code using TDD [closed]
What would be a good example of the use of TDD in large, real-life, complex, projects? All the examples I've seen so far are toy projects for the purpose of a book or a paper...
Can you name an ...
13
votes
9answers
4k views
Are too many if-else statements for validation bad? [duplicate]
From the book Professional Enterprise .Net, which has 5 star rating on Amazon that I am doubting after having a read through. Here is a Borrower class (In C# but it's pretty basic; anyone can ...
20
votes
5answers
2k views
Why can't Java/C# implement RAII?
Question:
Why can't Java/C# implement RAII?
Clarification:
I am aware the garbage collector is not deterministic. So with the current language features it is not possible for an object's Dispose() ...
19
votes
3answers
13k views
what is message passing in OO?
I've been studying OO programming, primarily in C++, C# and Java. I thought I had a good grasp on it with my understanding of encapsulation, inheritance and polymorphism (as well as reading a lot of ...
0
votes
2answers
261 views
How to enforce good coding style in team? [duplicate]
Even if I don't like enforcing people to do things (and I believe that it may decline the productivity and cause anger), I really want to enforce good coding style.
Is there a way to set up ...
4
votes
5answers
1k views
Switching Programming Languages [duplicate]
I'm a senior level Delphi developer looking for move into either C# or possibly Java roles. I have around 8 years of development experience of which pretty much all of it is in Delphi, I have very ...
9
votes
9answers
443 views
Studies on code documentation productivity gains/losses
After much searching, I have failed to answer a basic question pertaining to an assumed known in the software development world:
WHAT IS KNOWN:
Enforcing a strict policy on adequate code ...
4
votes
9answers
1k views
The definition of C-based language
What is the definition of C-based language?
Is C# considered to be C-based?
Is Java considered to be C-based?
Furthermore, what does it mean for a language to be based on another language anyway?
18
votes
3answers
11k views
Which is a better practice - helper methods as instance or static?
This question is subjective but I was just curious how most programmers approach this. The sample below is in pseudo-C# but this should apply to Java, C++, and other OOP languages as well.
Anyway, ...
9
votes
6answers
686 views
Is there an infinite amount of knowledge in a programming language?
I can program in Java, C#, C, Scala, and Javascript fluently. I'm comfortable with Objective-C, but I don't remember the conventions used for memory management. I can read Python and Ruby and I've ...
6
votes
15answers
2k views
Why OOP is enforced in Java and C#? [closed]
In many other languages like C++ and Javascript, OOP is optional. Procedural code is ok. But in languages like Java and C#, OOP is somewhat enforced. Everything is to be a part of a class or an ...
6
votes
8answers
3k views
Would Java programmers hire C# programmers? [closed]
I learned and used Java in college. After graduating, I got a job in C#. Two years after, there are a lot more positions in Java. Would I have a good chance to be hired as a Java programmer? What ...
1
vote
5answers
913 views
Transitioning To Java [duplicate]
I'm primarily a VBA/VB3-6/VB.Net developer of 15+ years with several years of C# experience. Myself and another developer (a seasoned senior level java developer) were hired on at this new company at ...
5
votes
5answers
2k views
How to switch From Java to .Net? [closed]
Has anyone out there done this? Did you have to spend a few years learning .NET before you could get a job or were there employers just willing to throw you into the fire based on your Java ...