<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Jan Varwig &#187; c#</title>
	<atom:link href="http://jan.varwig.org/archive/tag/c/feed" rel="self" type="application/rss+xml" />
	<link>http://jan.varwig.org</link>
	<description>Somewhere between Hello World and HAL9000</description>
	<lastBuildDate>Wed, 17 Mar 2010 11:12:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>The joys of C++</title>
		<link>http://jan.varwig.org/archive/the-joys-of-c</link>
		<comments>http://jan.varwig.org/archive/the-joys-of-c#comments</comments>
		<pubDate>Fri, 19 Oct 2007 13:11:59 +0000</pubDate>
		<dc:creator>Jan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[c#]]></category>

		<guid isPermaLink="false">http://jan.varwig.org/archiv/the-joys-of-c</guid>
		<description><![CDATA[Quick, why does this give me a compiler error? &#160; if &#160; &#160; &#160;&#40;dIntersectionZ &#60; &#160;box.GetChild&#40;0,0,0&#41;.GetBox&#40;&#41;.Min.z&#41; Assert&#40;false&#41;; &#160; else if &#40;dIntersectionZ &#60; &#160;box.GetChild&#40;0,0,1&#41;.GetBox&#40;&#41;.Min.z&#41; z = 0; &#160; else if &#40;dIntersectionZ &#60; &#160;box.GetChild&#40;0,0,2&#41;.GetBox&#40;&#41;.Min.z&#41; z = 1; &#160; else if &#40;dIntersectionZ &#60;= box.GetChild&#40;0,0,2&#41;.GetBox&#40;&#41;.Max.z&#41; z = 2; &#160; else &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>Quick, why does this give me a compiler error?</p>

<div class="dean_ch" style="white-space: wrap;"><br />
&nbsp; <span class="kw1">if</span> &nbsp; &nbsp; &nbsp;<span class="br0">&#40;</span>dIntersectionZ &lt; &nbsp;box.<span class="me1">GetChild</span><span class="br0">&#40;</span><span class="nu0">0</span>,<span class="nu0">0</span>,<span class="nu0">0</span><span class="br0">&#41;</span>.<span class="me1">GetBox</span><span class="br0">&#40;</span><span class="br0">&#41;</span>.<span class="me1">Min</span>.<span class="me1">z</span><span class="br0">&#41;</span> Assert<span class="br0">&#40;</span><span class="kw2">false</span><span class="br0">&#41;</span>;<br />
&nbsp; <span class="kw1">else</span> <span class="kw1">if</span> <span class="br0">&#40;</span>dIntersectionZ &lt; &nbsp;box.<span class="me1">GetChild</span><span class="br0">&#40;</span><span class="nu0">0</span>,<span class="nu0">0</span>,<span class="nu0">1</span><span class="br0">&#41;</span>.<span class="me1">GetBox</span><span class="br0">&#40;</span><span class="br0">&#41;</span>.<span class="me1">Min</span>.<span class="me1">z</span><span class="br0">&#41;</span> z = <span class="nu0">0</span>;<br />
&nbsp; <span class="kw1">else</span> <span class="kw1">if</span> <span class="br0">&#40;</span>dIntersectionZ &lt; &nbsp;box.<span class="me1">GetChild</span><span class="br0">&#40;</span><span class="nu0">0</span>,<span class="nu0">0</span>,<span class="nu0">2</span><span class="br0">&#41;</span>.<span class="me1">GetBox</span><span class="br0">&#40;</span><span class="br0">&#41;</span>.<span class="me1">Min</span>.<span class="me1">z</span><span class="br0">&#41;</span> z = <span class="nu0">1</span>;<br />
&nbsp; <span class="kw1">else</span> <span class="kw1">if</span> <span class="br0">&#40;</span>dIntersectionZ &lt;= box.<span class="me1">GetChild</span><span class="br0">&#40;</span><span class="nu0">0</span>,<span class="nu0">0</span>,<span class="nu0">2</span><span class="br0">&#41;</span>.<span class="me1">GetBox</span><span class="br0">&#40;</span><span class="br0">&#41;</span>.<span class="me1">Max</span>.<span class="me1">z</span><span class="br0">&#41;</span> z = <span class="nu0">2</span>;<br />
&nbsp; <span class="kw1">else</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Assert<span class="br0">&#40;</span><span class="kw2">false</span><span class="br0">&#41;</span>;<br />
&nbsp;</div>

<p>The compiler complains that the <code>else</code> in the second line does not belong to any <code>if</code>.<span id="more-65"></span></p>

<p><code>Assert</code> isn&#8217;t a function, duh!</p>

<p>From <em>MyAssert.h</em>, included in some completely inobvious place:</p>

<div class="dean_ch" style="white-space: wrap;"><br />
&nbsp; &nbsp; #define Assert(x) &nbsp; if (!(x)) {printf(&quot;Error:\n &nbsp;File %s\n &nbsp;Function %s\n &nbsp;→<br />
&nbsp; &nbsp; Line %i;,__FILE__,__FUNCTION__,__LINE__);{ static FILE *fOut; static char &nbsp;→<br />
&nbsp; &nbsp; sName[100]; _snprintf_s(sName,99,&quot;Error_%x.log&quot;,sName); fopen_s(&amp;fOut,sNam →<br />
&nbsp; &nbsp; e,&quot;wb&quot;); if(fOut){fprintf(fOut,&quot;Error:\n &nbsp;File %s\n &nbsp;Function %s\n &nbsp;Line % →<br />
&nbsp; &nbsp; i&quot;,__FILE__,__FUNCTION__,__LINE__);fclose(fOut);}} assert(0); exit(999);}<br />
&nbsp;</div>

<p>Moral of the story:<br />
Preprocessor macros make for some really entertaining afternoons.<br />
Oh, and avoid C++ wherever possible.</p>
]]></content:encoded>
			<wfw:commentRss>http://jan.varwig.org/archive/the-joys-of-c/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>F# Observations</title>
		<link>http://jan.varwig.org/archive/f-sharp-observations</link>
		<comments>http://jan.varwig.org/archive/f-sharp-observations#comments</comments>
		<pubDate>Sat, 11 Aug 2007 23:10:59 +0000</pubDate>
		<dc:creator>Jan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[clr]]></category>
		<category><![CDATA[f#]]></category>
		<category><![CDATA[grid-computing]]></category>
		<category><![CDATA[haskell]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[monads]]></category>
		<category><![CDATA[ocaml]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[tutorial]]></category>

		<guid isPermaLink="false">http://jan.varwig.org/archiv/f-sharp-observations</guid>
		<description><![CDATA[I&#8217;m feeling all mad-scientistic tonight, sipping coke, with 30 tabs open in Opera :) On my journey into the weird world of functional programming on the .NET CLR, I continue to stumble upon interesting stuff. Papers, articles, interviews, each worthy of hours of dedication. Alas, my day still has only 24 hours (I need to [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m feeling all mad-scientistic tonight, sipping coke, with 30 tabs open in Opera :)</p>

<p>On my journey into the weird world of functional programming on the .NET CLR, I continue to stumble upon interesting stuff.
Papers, articles, interviews, each worthy of hours of dedication.
Alas, my day still has only 24 hours (I need to work around that somehow), so at the time being I can&#8217;t do much more than glance over everything.<span id="more-57"></span></p>

<p>The questions I was trying to answer during the last few days were (and to a great degree still are):</p>

<ul>
<li>What is the cost of using threads on the CLR and how does F# handle them?</li>
<li>Is F# fast enough to handle computationally-intensive tasks?</li>
<li>Is F# suited for distributed programming?</li>
</ul>

<h3>The cost of using threads on the CLR</h3>

<p>The answer to that question is pretty clear, fortunately. <a href="http://discuss.joelonsoftware.com/default.asp?design.4.435389.16">This thread</a> on the Joel on Software Discussion Board pretty much deals with the question from <a href="/archiv/an-apple-a-day">my last post</a>: <strong>.NET/F# vs. Erlang</strong>.
The initial question in the thread was along the lines of &#8220;I want to do computation with a great bunch (n x 1000) of agents, represented by processes, communicating via messages. Should I use F# or Erlang?&#8221;.</p>

<p>The first answer was already very helpful to me:</p>

<blockquote>
  <p>My understanding is that the .net threads are very heavy weight (128K) when compared to erlang processes (300-400 bytes).</p>
</blockquote>

<p>So, no native CLR threads for larger numbers of processes. After a bit of thinking though, this turns out not to be a problem. What I am planning can easily (perhaps even best) achieved by a few, long-running threads. Yet, the need for many agents and lots of communication might turn up later and I don&#8217;t want to lock myself into something that&#8217;ll leaves me in the lurch later.</p>

<p>Further down the thread, someone posted links to a Microsoft Project called <a href="http://msdn.microsoft.com/msdnmag/issues/06/09/concurrentaffairs/default.aspx">Concurrency and Coordination Runtime</a>, used in the Robotics Studio and fit for precisely this problem.<br />
I have only had a peek into the CCR and if I understand the indroduction of <a href="http://research.microsoft.com/~satnams/">Satnam Singh</a>&#8216;s Paper <a href="https://urresearch.rochester.edu/handle/1802/2105">An Asynchronous Messaging Library for C#</a> correctly, it&#8217;s a library that runs on the unmodified CLR and provides green threads (or something similar) via <a href="http://en.wikipedia.org/wiki/Continuation-passing_style">CPS</a> with good performance.</p>

<p>Im definetly gonna look deeper into this <strike>and I hope there&#8217;s a way to test it out</strike>. Hey cool, it&#8217;s <a href="http://msdn2.microsoft.com/de-de/robotics/bb521232.aspx">free for non-commercial uses</a>!</p>

<h3> Performance of F# and distributed programming</h3>

<p>Its nice <a href="http://www.jroller.com/dmdevito/entry/thoughts_about_java_c_future">performance</a> seems to always be among the major points proponents of OCaml bring up and it was one the major reasons for me to consider F#/OCaml. Hard numbers on F# performance for this weren&#8217;t that easy to find though.
The <a href="http://research.microsoft.com/fsharp/fsharp.aspx">official F# page</a> only claims it to have &#8220;a performance profile like that of C#&#8221;.
<a href="http://dotnet.sys-con.com/read/217534.htm">This article</a> however turned out quite informative:</p>

<blockquote>
  <p>Like OCaml, F# is excellent at writing tools for symbolic programming. Examples of this type of programming include static analysis, compilers, and other <strong>sophisticated analyses over structured data terms</strong>. Remember using Maple or Matlab? How about Mathematica? That&#8217;s what writing F# is like. If F# is to be used to analyze various complex problems, then harnessing it to a virtual supercomputer seemed like a logical thing. Slated to learn two new technologies, I was hoping I hadn&#8217;t bit off more than I could chew.</p>
</blockquote>

<p>(emphasis mine)</p>

<p>This is exactly my situation. The article describes an experiment in distributing a computationally intensive algorithm over multiple machines using <a href="http://www.sourceforge.net/projects/alchemi">Alchemi</a>, a .NET Grid Computing Framework which was deployed first using pure C#, then F# wrapped in C# and finally pure F#. The results?</p>

<blockquote>
  <p>Without any optimization the F# implementation took 453 ms. C# finished up in 62 ms. Turning optimization on caused the C# results to drop to 46 ms. And, most shocking of all, the F# was dead even at 46 ms! Apparently, the F# compiler does an excellent job optimizing the code. Continuing on, I ran the entire C# and F# grid applications against one another. Without any optimization the C# code took 3.9 seconds to calculate 100 digits of pi while F# only took 2.8 seconds. Optimizing this application showed that F# would finish in 1.5 seconds while C# would not complete any faster than 2.6 seconds.</p>
</blockquote>

<p>Nice!</p>

<h3>Next steps</h3>

<p>I&#8217;m definetly gonne work my way through one of the excellent OCaml tutorials online.<br />
The ones that seem recommended most often are</p>

<ul>
<li><a href="http://pauillac.inria.fr/~remy/cours/appsem/ocaml.pdf">Using, Understanding, and Unraveling the OCaml Language</a> by Didier Rémy</li>
<li><a href="http://www.cs.caltech.edu/courses/cs134/cs134b/book.pdf">Introduction to the Objective Caml Programming Language</a> by <a href="http://www.cs.caltech.edu/~jyh/">Jason Hickey</a></li>
<li><a href="http://caml.inria.fr/pub/docs/oreilly-book/">Developing Applications With Objective Caml</a>, an entire book, available online with whopping 750 pages</li>
</ul>

<h3>More Stuff</h3>

<p>Like always, browsing the web got me sidetracked here and there instead of keeping me focused on F#.<br />
I want to share the most interesting discoveries with you.</p>

<ul>
<li><a href="http://www.albahari.com/threading/">Threading in C#</a> by Joseph Albahari is a pretty profound free online book about, well, threading in C#</li>
<li><a href="http://channel9.msdn.com/Showpost.aspx?postid=230438">Brian Beckman: Monads, Monoids, and Mort</a> is a Channel 9  interview in which Brian tells a bit of history about his career, chats about functional programming, nicely explains Monoids and Monads on the way and introduces a pretty shocking statement about the relation between VisualBasic and C# at Microsoft Research.</li>
<li><a href="http://fsharpnews.blogspot.com/">F# News</a> is a blog that deals solely with, who&#8217;d have guessed it, F#</li>
<li><a href="http://www.ffconsultancy.com/products/fsharp_for_visualization/index.html">F# for Visualization</a> is a book from Flying Frog. The page links to an impressive Demo illustrating F#&#8217;s performance.</li>
<li><a href="http://www.haskell.org/haskellwiki/Meet_Bob_The_Monadic_Lover">Meet Bob the Monadic Lover</a> seems to be a very entertaining introduction to monads. I haven&#8217;t read it yet though, I&#8217;m still fighting my way through&#8230;</li>
<li><a href="http://www.cs.toronto.edu/~sme/presentations/cat101.pdf">Category Theory for Beginners</a>, great slides from an introductory course into category theory which focus on the motivations behind and practical uses of category theory for computer scientists.</li>
</ul>

<p>Holy crap, that was a long post.</p>
]]></content:encoded>
			<wfw:commentRss>http://jan.varwig.org/archive/f-sharp-observations/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>An apple a day&#8230;</title>
		<link>http://jan.varwig.org/archive/an-apple-a-day</link>
		<comments>http://jan.varwig.org/archive/an-apple-a-day#comments</comments>
		<pubDate>Tue, 31 Jul 2007 21:29:27 +0000</pubDate>
		<dc:creator>Jan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[Studium]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[erlang]]></category>
		<category><![CDATA[functional]]></category>
		<category><![CDATA[haskell]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[lisp]]></category>
		<category><![CDATA[ocaml]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[Ruby]]></category>

		<guid isPermaLink="false">http://jan.varwig.org/archiv/an-apple-a-day</guid>
		<description><![CDATA[Wie heisst die Faustregel doch so schön? &#8220;Lerne jedes Jahr eine neue Programmiersprache&#8221; Bisher schlage ich mich damit ganz gut: 2007: ein bißchen Python 2006: C#, Ruby, Javascript 2005: genug C++ um da in Zukunft einen Bogen herum zu machen, genug Haskell um ein permanentes distanziertes Interesse zu erhalten das vielleicht irgendwann durchschlägt in ernsthafte [...]]]></description>
			<content:encoded><![CDATA[<p>Wie heisst die Faustregel doch so schön? &#8220;Lerne jedes Jahr eine neue Programmiersprache&#8221;</p>

<p>Bisher schlage ich mich damit ganz gut:</p>

<p>2007: ein bißchen Python<br />
2006: C#, Ruby, Javascript<br />
2005: genug C++ um da in Zukunft einen Bogen herum zu machen, genug Haskell um ein permanentes distanziertes Interesse zu erhalten das vielleicht irgendwann durchschlägt in ernsthafte Auseinandersetzung.<br />
2003/2004: Java<br />
1999-2002: PHP, SQL<span id="more-50"></span></p>

<p>In der Hoffnung, dieses Jahr noch die Gelegenheit dafür zu haben, bin ich gerade dabei mich zu orientieren womit ich mich als nächstes befassen soll. Bis vor 2-3 Wochen stand Lisp &#8211;und das seit langem schon&#8211; ganz oben auf der Liste. Vor etwa einem Monat aber hat mich der <a href="http://lambda-the-ultimate.org/node/2315">Haskell Web Store</a> Post auf <a href="http://lambda-the-ultimate.org/">LtU</a> wieder dazu gebracht, mein Haskell Script herauszuholen und die Schönheit funktionaler Programmierung und Haskells Typsystems zu bewundern.</p>

<p>Ich weiss nicht wie ich darauf kam, aber gestern fing alles damit an dass, ich &#8220;Erlang vs. Haskell&#8221; bei Google eingegeben habe. Inzwischen knubbeln sich auf Platz 1 meiner Liste 2 Sprachen, Lisp ist auf Platz 2 gerutscht und Haskell wieder auf die 3. Konkret bin ich gerade fasziniert von <a href="http://www.erlang.org/">Erlang</a> sowie <a href="http://caml.inria.fr/ocaml/">OCaml</a>.</p>

<p>Erlang wird wegen seiner extremen Robustheit und der überragenden Fähigkeit zum Multiprocessing schon lange als das nächste große Ding gehandelt. <a href="http://yarivsblog.com/">Yariv&#8217;s Blog</a> versprüht einen Enthusiasmus der mit dem kribbeligen Gefühl zu vergleichen ist als mir die Lichter von Ruby aufgingen. Leider habe ich gerade keinen Bedarf einer hochskalierbaren Webanwendung.</p>

<p>OCaml hingegen ermöglicht mir, in Form von <a href="http://research.microsoft.com/fsharp/fsharp.aspx">F#</a>, funktional in der .NET Umgebung zu programmieren. Und <em>das</em> liesse sich mit ein wenig Phantasie vielleicht sogar zu einem Diplomarbeitsthema machen&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://jan.varwig.org/archive/an-apple-a-day/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>C# vs. The World</title>
		<link>http://jan.varwig.org/archive/c-vs-the-world</link>
		<comments>http://jan.varwig.org/archive/c-vs-the-world#comments</comments>
		<pubDate>Mon, 13 Nov 2006 20:38:12 +0000</pubDate>
		<dc:creator>Jan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[Studium]]></category>
		<category><![CDATA[c#]]></category>

		<guid isPermaLink="false">http://jan.varwig.org/archiv/c-vs-the-world</guid>
		<description><![CDATA[Meine erste Einstellung gegenüber C# war ablehnend. Wozu ein neue Sprache die kaum wesentliche Vorteile gegenüber Java bietet? Nach näherer Beschäftigung mit .NET 2.0 sah die Sache besser aus. Properties? Nice! Anonyme Funktionen? Praktisch!, Closures und Iteratoren? Yay! Langsam schien die Entscheidung doch nicht die verkehrteste zu sein. Bei der konkreten Arbeit offenbaren sich jedoch [...]]]></description>
			<content:encoded><![CDATA[<p>Meine erste Einstellung gegenüber C# war ablehnend. Wozu ein neue Sprache die kaum wesentliche Vorteile gegenüber Java bietet? Nach näherer Beschäftigung mit .NET 2.0 sah die Sache besser aus. Properties? Nice! Anonyme Funktionen? Praktisch!, Closures und Iteratoren? Yay! Langsam schien die Entscheidung doch nicht die verkehrteste zu sein.<br />
Bei der konkreten Arbeit offenbaren sich jedoch allmählich die Unterschiede zwischen Theorie und Praxis:</p>

<ul>
<li>Die ganzen coolen Funktionen und Konstrukte verstecken sich hinter einem Wust redundanter Syntax, die nur duch viele automatische Funktionen in VisualStudio 8 erträglicher wird.</li>
<li>VisualStudio kommt zwar mit einem Debugger, ein Speicherprofiler muss aber extern installiert werden, ein Laufzeit-Profiler kostet extra.</li>
<li>Wenn ich den erwische der die Idee hatte, XML als Markup für die DocComments zu benutzen&#8230;</li>
<li>Viele der netten Features sind in ihrer tatsächlichen Verwendung nur noch halb so nett. Das Programmieren in streng getypten Sprachen ist eine Qual wenn man einmal mit Ruby gearbeitet hat.</li>
<li>Die Doku im MSDN ist zwar umfangreich, aber verwirrend und schlecht organisiert. Die Methoden, Properties und Member der Klassen stehen alle auf jeweils einer einzelnen Seite mit unzähligen Links, die <em>irgendwohin</em> führen. Soviel Redundanz führt auch dazu, dass Suchergebnisse selten akkurat sind und die gewünschte Information erst nach ein paar weiteren Klicks gefunden wird.</li>
</ul>

<p>C# ist im Ansatz eine gute Idee, mein ungutes Gefühl wird aber vor allem duch die Implementierung durch Microsoft verursacht. Man merkt schnell dass man hier mit proprietärer Technik arbeitet wenn viele wichtige Tools entweder nicht verfügbar sind oder Geld kosten (oder kennt jemand einen brauchbaren freien Profiler?).</p>
]]></content:encoded>
			<wfw:commentRss>http://jan.varwig.org/archive/c-vs-the-world/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Bessere Jobs dank C# ?</title>
		<link>http://jan.varwig.org/archive/bessere-jobs-dank-c</link>
		<comments>http://jan.varwig.org/archive/bessere-jobs-dank-c#comments</comments>
		<pubDate>Fri, 03 Nov 2006 16:25:02 +0000</pubDate>
		<dc:creator>Jan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[Studium]]></category>
		<category><![CDATA[c#]]></category>

		<guid isPermaLink="false">http://jan.varwig.org/archiv/bessere-jobs-dank-c</guid>
		<description><![CDATA[Dritte Woche PG, so langsam geht es los. Müssen die ersten Entscheidungen getroffen werden, gibt es auseinandergehende Meinungen. Die Frage: Mit welcher Sprache wollen wir das Projekt implementieren? Zur Auswahl stehen C# und Java. C++ schied glücklicherweise schon in der Vorrunde aus. Unsere Ausgangssituation sieht so aus, dass alle &#8220;so ein bißchen&#8221; Java Erfahrung aus [...]]]></description>
			<content:encoded><![CDATA[<p>Dritte Woche PG, so langsam geht es los. Müssen die ersten Entscheidungen getroffen werden, gibt es auseinandergehende Meinungen.</p>

<p>Die Frage: Mit welcher Sprache wollen wir das Projekt implementieren? Zur Auswahl stehen C# und Java. C++ schied glücklicherweise schon in der Vorrunde aus.</p>

<p>Unsere Ausgangssituation sieht so aus, dass alle &#8220;<em>so ein bißchen</em>&#8221; Java Erfahrung aus dem Sopra haben, zwei Leute über etwas weniger Erfahrung mit C# verfügen. Kriterien die die Entscheidungsfindung erleichern sollten waren</p>

<ul>
<li>Verfügbarkeit und Qualität von Bibliotheken</li>
<li>Performance</li>
<li>3D-Grafik Wiedergabe</li>
</ul>

<p>und zu guter Letzt</p>

<ul>
<li>Vertrautheit mit der Sprache</li>
</ul>

<p>Über die ersten drei Punkte bestand im wesentlichen Einigkeit, am letzten schieden sich jedoch die Geister, zwei Argumente stehen sich jetzt gegenüber:</p>

<p>Gegen C# spricht, dass so gut wie keiner von uns damit Erfahrung hat und dadurch neben den eigentlichen Anwendungsproblemen noch das Einarbeiten in eine völlig neue Sprachumgebung als Aufgabe hinzukommt. Der damit verbundene Aufwand ist nicht zu unterschätzen.</p>

<p>Zur Verteidigung der Verwendung von C# wird angeführt, dass man die PG dazu nutzen wolle, sich neben Java noch eine weitere, auf dem Arbeitsmarkt augenscheinlich momentan beliebte Sprache anzueignen.</p>

<p>Dieses Argument steht allerdings auf keiner guten Grundlage.</p>

<p>Vor allem ist der Wunsch eine neue Sprache zu lernen eine reine <em>Privatangelegenheit</em> und hat eigentlich keinen Bezug zu den Zielen des Projektes. Vorausgesetzt dass Java und C# unter allen erwähnten Kriterien äquivalent oder zumindest ähnlich sind, wird durch die Verwendung von C# nichts gewonnen, im Gegenteil, die Entwicklung wird durch den beschriebenen Lernaufwand noch behindert.</p>

<p>Darüberhinaus gibt es noch eine falsche, zumindest aber zweifelhafte Annahme die dem Argument zugrundeliegt. Leider konnte ich den Hintergrund dieses Gedankens in der Sitzung auf die Schnelle nicht überzeugend formulieren und habe ihn erstmal für mich behalten. Jetzt habe ich mich ein bißchen hingesetzt, nachgedacht und festgehalten was ich genau meine.</p>

<p><strong>Die Idee, mit dem Lernen von C# jetzt seine Berufschancen zu erhöhen ist Unsinn</strong></p>

<p>Aus &#8211;im wesentlichen&#8211; zwei Gründen:</p>

<p>Wem wirklich etwas daran liegt Sprachen zu lernen, der wartet nicht darauf dass die Uni auf ihn zukommt. Eigeninitiative und die Fähigkeit sich für eine Sache so zu interessieren dass man seine Freizeit darin investiert sind wesentlich mehr wert als C#. Paul Graham erläutert das Phänomen in <a href="http://www.paulgraham.com/pypar.html">Python Paradox</a>:</p>

<blockquote>
  <p>It&#8217;s a lot of work to learn a new programming language. And people don&#8217;t learn Python because it will get them a job; they learn it because they genuinely like to program and aren&#8217;t satisfied with the languages they already know.</p>
  
  <p>Which makes them exactly the kind of programmers companies should want to hire. Hence what, for lack of a better name, I&#8217;ll call the Python paradox: if a company chooses to write its software in a comparatively esoteric language, they&#8217;ll be able to hire better programmers, because they&#8217;ll attract only those who cared enough to learn it. And for programmers the paradox is even more pronounced: the language to learn, if you want to get a good job, is a language that people don&#8217;t learn merely to get a job.</p>
  
  <p>Only a few companies have been smart enough to realize this so far. But there is a kind of selection going on here too: they&#8217;re exactly the companies programmers would most like to work for. Google, for example. When they advertise Java programming jobs, they also want Python experience.</p>
</blockquote>

<p>Nun bin ich nicht so naiv zu glauben, alle deutschen Personalchefs würden Paul Graham lesen (sehr schade eigentlich), aber wenn man auf sein Engagement und seine Bandbreite an Programmiersprachen hinweist, dürfte es kein Problem sein, jemanden davon zu überzeugen, dass man sich innerhalb kürzester Zeit in jede beliebige neue Sprache einarbeiten kann.</p>

<p>Umgekehrt aber einem der Personalchefs, die Graham kennen, von der eigenen Flexibilität und Begeisterung für Softwareentwicklung zu erzählen, wenn alle Spracherfahrung die man vorzuweisen hat ein bißchen Java und C# im Rahmen halbfreiwilliger Uni-Veranstaltungen sind, dürfte schwierig werden.</p>
]]></content:encoded>
			<wfw:commentRss>http://jan.varwig.org/archive/bessere-jobs-dank-c/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
