Re: [LAU] OT: C or C++?

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Philipp Überbacher <hollunder@...>, linux-audio-user <linux-audio-user@...>
Date: Thursday, October 14, 2010 - 8:36 pm

On Thu, 14 Oct 2010 20:10:52 +0200, Philipp Überbacher wrote

But that's not the language, that's the quality of the people teaching it
there.

> What does the following example evaluate to?

$ cat > Foo.ava
class Foo
{
static { System.out.println( 1.2+3+"||"+3+2.1 ); System.exit( 0 ); }
}
^D
$ javac Foo.java
$ java Foo

C'm on, that's not really that hard, no Eclipse, no packages, no real object.

> I think there's far too much distracting mess to sort out before you

What's distracting here?

Regarding your example -my main question would be: what do _you_ expect from that
code. 'I'd say you get what you ask for.
Java has a defined evaluation order (JLS 15.7) - left to right, and does type
conversion
_and_ does overloading of methods. All of this are basic design decisions
which any language
has to take. Are you criticising the choices the Java team made? Do you prefer
the Ocaml way?
So "1 + 2", or "3.0 +. 2.1" - and then the horrible "add_int_to_float 1 +
2.0" ????
That for shure will be less confusing to beginners :-/

BTW,

1] 1.2 + 3 = 4.2 since you can't convert a float to an int but an int to a
float

2] 4.2 + "||" need to convert 4.2 to a string, because the other way
round isn't supported

3] ... go on ...

Cheers, RalfD

P.S.: if possible i try to avoid programming in Java, but for totally
different reasons.

>

--
R. Mattes -- Systemeinheitsstreichler
Hochschule fuer Musik Freiburg
rm@inm.mh-freiburg.de

_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-user

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[LAU] OT: C or C++?, Josh Lawrence, (Wed Oct 13, 8:42 pm)
Re: [LAU] OT: C or C++?, Josh Lawrence, (Fri Oct 15, 12:26 am)
Re: [LAU] OT: C or C++?, Ken Restivo, (Thu Oct 21, 12:12 am)
Re: [LAU] OT: C or C++?, Atte André Jensen, (Mon Oct 18, 10:25 am)
Re: [LAU] OT: C or C++?, James Morris, (Thu Oct 14, 1:30 am)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 1:17 am)
Re: [LAU] OT: C or C++?, Josh Lawrence, (Thu Oct 14, 3:06 am)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 4:17 am)
Re: [LAU] OT: C or C++?, Ng Oon-Ee, (Thu Oct 14, 5:49 am)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 8:40 am)
Re: [LAU] OT: C or C++?, Tim Clewlow, (Thu Oct 14, 12:28 am)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 1:05 am)
Re: [LAU] OT: C or C++?, Tim Clewlow, (Thu Oct 14, 1:37 am)
Re: [LAU] OT: C or C++?, david, (Thu Oct 14, 8:50 am)
Re: [LAU] OT: C or C++?, Arnold Krille, (Wed Oct 13, 11:00 pm)
Re: [LAU] OT: C or C++?, , (Wed Oct 13, 10:03 pm)
Re: [LAU] OT: C or C++?, Folderol, (Wed Oct 13, 10:11 pm)
Re: [LAU] OT: C or C++?, , (Wed Oct 13, 10:55 pm)
Re: [LAU] OT: C or C++?, Robin Gareus, (Wed Oct 13, 10:32 pm)
Re: [LAU] OT: C or C++?, Bjoern Lindig, (Thu Oct 14, 6:25 pm)
Re: [LAU] OT: C or C++?, Robin Gareus, (Thu Oct 14, 7:23 pm)
Re: [LAU] OT: C or C++?, Philipp Überbacher, (Thu Oct 14, 3:17 pm)
Re: [LAU] OT: C or C++?, Gabriel M. Beddingfield, (Wed Oct 13, 9:16 pm)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 1:11 am)
Re: [LAU] OT: C or C++?, Joshua Boyd, (Thu Oct 14, 3:27 pm)
Re: [LAU] OT: C or C++?, Erik de Castro Lopo, (Thu Oct 14, 8:14 pm)
Re: [LAU] OT: 2 minute intro to type systems (was C or C++?), Erik de Castro Lopo, (Thu Oct 14, 8:44 pm)
Re: [LAU] OT: 2 minute intro to type systems (was C or C++?), Erik de Castro Lopo, (Fri Oct 15, 10:51 am)
Re: [LAU] OT: 2 minute intro to type systems (was C or C++?), Philipp Überbacher, (Fri Oct 15, 6:30 am)
Re: [LAU] OT: 2 minute intro to type systems (was C or C++?), Harry Van Haaren, (Thu Oct 14, 9:23 pm)
Re: [LAU] OT: C or C++?, Bernardo Barros, (Thu Oct 14, 4:08 pm)
Re: [LAU] OT: C or C++?, Nick Dokos, (Thu Oct 14, 3:50 pm)
Re: [LAU] OT: C or C++?, Gabriel M. Beddingfield, (Thu Oct 14, 3:55 pm)
Re: [LAU] OT: C or C++?, R. Mattes, (Thu Oct 14, 4:39 pm)
Re: [LAU] OT: C or C++?, Gabriel M. Beddingfield, (Thu Oct 14, 5:02 pm)
Re: [LAU] OT: C or C++?, Kris Calabio, (Thu Oct 14, 5:22 pm)
Re: [LAU] OT: C or C++?, Philipp Überbacher, (Thu Oct 14, 6:10 pm)
Re: [LAU] OT: C or C++?, R. Mattes, (Thu Oct 14, 8:36 pm)
Re: [LAU] OT: C or C++?, Philipp Überbacher, (Fri Oct 15, 7:13 am)
Re: [LAU] OT: C or C++?, Simon Wise, (Fri Oct 15, 11:28 am)
Re: [LAU] OT: C or C++?, R. Mattes, (Fri Oct 15, 9:31 am)
Re: [LAU] OT: C or C++?, Dave Phillips, (Fri Oct 15, 10:23 am)
Re: [LAU] OT: C or C++?, James Morris, (Fri Oct 15, 7:43 am)
Re: [LAU] OT: C or C++?, david, (Fri Oct 15, 7:21 am)
Re: [LAU] OT: C or C++?, Philipp Überbacher, (Fri Oct 15, 7:45 am)
Re: [LAU] OT: C or C++?, david, (Sun Oct 17, 8:53 am)
Re: [LAU] OT: C or C++?, Kris Calabio, (Thu Oct 14, 8:05 pm)
Re: [LAU] OT: C or C++?, Bernardo Barros, (Thu Oct 14, 8:09 pm)
Re: [LAU] OT: C or C++?, Ken Restivo, (Thu Oct 21, 12:17 am)
Re: [LAU] OT: C or C++?, Folderol, (Thu Oct 14, 9:22 pm)
Re: [LAU] OT: C or C++?, Veronica Merryfield, (Thu Oct 14, 8:40 pm)
Re: [LAU] OT: C or C++?, Orcan Ogetbil, (Thu Oct 14, 8:23 pm)
Re: [LAU] OT: C or C++?, R. Mattes, (Thu Oct 14, 8:52 pm)
Re: [LAU] OT: C or C++?, Philipp Überbacher, (Fri Oct 15, 6:55 am)
Re: [LAU] OT: C or C++?, , (Thu Oct 14, 9:20 pm)
Re: [LAU] OT: C or C++?, Brett McCoy, (Thu Oct 14, 9:16 pm)
Re: [LAU] OT: C or C++?, Orcan Ogetbil, (Thu Oct 14, 9:05 pm)
Re: [LAU] OT: C or C++?, R. Mattes, (Thu Oct 14, 9:19 pm)
Re: [LAU] OT: C or C++?, Orcan Ogetbil, (Thu Oct 14, 9:43 pm)
Re: [LAU] OT: C or C++?, Chris Cannam, (Thu Oct 14, 9:23 am)
Re: [LAU] OT: C or C++?, Gabriel M. Beddingfield, (Thu Oct 14, 2:50 pm)
Re: [LAU] OT: C or C++?, Charles , (Wed Oct 13, 10:11 pm)
Re: [LAU] OT: C or C++?, Charles Henry, (Wed Oct 13, 10:07 pm)