Mar 9, 2020COVID-19, votre communauté, et vousÉcrit le 9 mars 2020 par Jeremy Howard and Rachel Thomas Traduction en français par Patrick Jayet et deepl.com. Article original. Nous sommes des data scientists, c’est-à-dire que notre travail consiste à comprendre comment analyser et interpréter les données. Lorsque nous analysons les données relatives au COVID-19, nous sommes très…Co Vid 1920 min readCo Vid 1920 min read
Published inXRB’s Blog·Jun 15, 2014Using Passbook for Boarding a FlightOn my trip to Berlin for the Scala Days conference, I used Passbook for the first time to store my boarding pass. I thought it would be interesting to share this first paperless boarding experience with you. When I did the check-in on Swiss’ website the day before my flight…General2 min readGeneral2 min read
Published inXRB’s Blog·Jul 10, 2010Scala Question Regarding readLineI have stumbled upon a weirdness regarding the behavior of readLine in Scala (at least with my current basic understanding of the language). The following snippet is supposed to read three times a line from standard in. But it reads 3 times the same line (the first). [code] (1 to 3) foreach { val line = Console.readLine i => println(line) } [/code] while the following snippet (very similar) behaves as expected (reading the three first line from stdin):English1 min readEnglish1 min read
Published inXRB’s Blog·May 22, 2010Java Quiz of the DayJava quiz of the day (easy): what gives Object[] a = new Integer[]{}; List<Object> b = new ArrayList<Integer>(); Response: we get an exception on the second line: Type mismatch: cannot convert from ArrayList<Integer> to List<Object> Arrays and Generics are not consistent. While for arrays, an array of some type is…English1 min readEnglish1 min read
Published inXRB’s Blog·May 19, 2010Java Quiz of the Day IIWhat gives: Integer a = 100, b = 100; Integer c = 200, d = 200; System.out.println( (a == b) == (c == d) ); // A Response: counter intuitively, the program prints ‘false’ out. Integer in Java is a non-native class, where ‘==’ means ‘reference equality’ (two variables are reference equal if they are pointing to the same object). From there we would expect the expression of line (A) to be reduced to ‘false == false’, but it is slightly more complicated: the Integer class has the particularity that all Integer (like Short) in the range [-128, 127] are shared. This means the two variables ‘a’ and ‘b’ are actually pointing to the same shared object. Hence the expression of line (A) is in fact reduced to ‘true == false’.English1 min readEnglish1 min read
Published inXRB’s Blog·May 19, 2010Java Quiz of the DayWhat gives Double a = null; Double b = a == null ? a : 1.0; Response: as strange as it can seem at first look, b is not equal to null after the second statement, but the code produces a NullPointerException. The reason for that is the type of the second expression (double) inside the ternery operator. The first expression ‘a’ of type Double is unboxed to double (calling doubleValue() on ‘a’ which is null), causing the NPE.English1 min readEnglish1 min read
Published inXRB’s Blog·Mar 31, 2010Sparse Files — Commands OverviewI was just checking which commands are supporting sparse files. I post hereafter a short overview of what I found out (working on Linux). Create a sparse file of 20 GiB: dd if=/dev/zero of=foo bs=1 count=1 seek=20G Check that a file is sparse: ls -alsh Compare the first versus second size column (the first one is the space taken on disk). Copy a sparse file: cp foo bar Copy already detects and handles correctly sparse files.English1 min readEnglish1 min read
Published inXRB’s Blog·Mar 30, 2010How to Know if a File on Linux is Sparse?A sparse file is a file which does not take more space on disk than needed. Such a file is usually used to store a partition image on disk, for instance with a virtualization solution like Xen. It’s super easy, to know if a file is sparse or not. …English1 min readEnglish1 min read
Published inXRB’s Blog·Mar 28, 2010GPGMail Compatible with Snow LeopardI had posted that some times ago on Twitter. There is a new version of the excellent GPGMail plug-in for Mail (OS X). Grab it, if you haven’t already. GPGMail for OS X 10.6.2 Just put it inside ~/Library/Mail/Bundles and restart Mail. (More information on GPGMail’s web page.) Edit: This is not an official version of GPGMail. There is still no official version of GPGMail compatible with Snow Leopard.English1 min readEnglish1 min read
Published inXRB’s Blog·Mar 27, 2010Extrabright Mix 03Check out my new mix 03. Extrabright Mix 03: electro to house with a squeeze of detroit and a drop of chill-out. Among others Gui Borrato, SMD remixed by DJ Pierre, Jori Hulkkonen, Miss Kittin & The Hacker, Mosca, Josh Wink, Black Dog, Clark plus a bunch of other great stuffs. [audio:Extrabright_Mix_03.mp3]English1 min readEnglish1 min read