« first day (529 days earlier)      last day (3487 days later) » 

12:00 AM
> Lazy evaluation refers to a variety of concepts that seek to avoid evaluation of an expression unless its value is needed, and to share the results of evaluation of an expression among all uses of its, so that no expression need be evaluated more than once.
 
Okay
 
Only a handful of questions though
 
user55340
@mjolka The true level of monstrosity would be if I had a number of people all come and write this code... Java, Haskell, Clojure, Python... all on the same day. Hmm?
 
........
 
@MichaelT some men do just want to watch the world burn, huh?
 
user55340
12:04 AM
Maybe get someone to do J too.
 
user55340
@mjolka you know... there's a person who knows mumps over on P.SE... I wonder...
 
user55340
MUMPS (Massachusetts General Hospital Utility Multi-Programming System) or alternatively M, is a general-purpose computer programming language that provides ACID (Atomic, Consistent, Isolated, and Durable) transaction processing. Its most unique and differentiating feature is its "built-in" database, enabling high-level access to disk storage using simple symbolic program variables and subscripted arrays, similar to the variables used by most languages to access main memory. The M database is a key-value database engine optimized for high-throughput transaction processing. As such it is in the...
 
user55340
Its not just something programmers tell interns to scare them... it exists.
 
user55340
GREPTHIS()
       N S,N,T,I,K,Q S I="K",S="11",K="l1",Q="R",T="K"
       I I=T D T
       Q:$Q Q Q
T  I I,S&K S S=S+K Q
 
user55340
Valid Mumps code.
 
user55340
12:05 AM
Its the shorter version of:
 
user55340
GREPTHIS()
       NEW SET,NEW,THEN,IF,KILL,QUIT SET IF="KILL",SET="11",KILL="l1",QUIT="RETURN",THEN="KILL"
       IF IF=THEN DO THEN
       QUIT:$QUIT QUIT QUIT ; (quit)
THEN  IF IF,SET&KILL SET SET=SET+KILL QUIT
 
@MichaelT - you should write this in LOLCODE, KTHXBAI.
2
... ftw.
50
Q: Down with FizzBuzz... LOL

Mat's MugThis post is the result of reading through and following the LOLCODE Specification 1.2, and writing and executing my code on compileonline.com. My "hello world" was going to be a fizzbuzz. I like it because it nicely illustrates the basics of a language - variables, operators, looping, condition...

 
user55340
 
did I hear ?
 
user55340
$ 'main' (--):
 \
 | /---------\
 | |         |
 | \    /-io-/
 \---e-<
        \-#
 
12:07 AM
monking!
 
> Data types: There is one universal datatype, which is implicitly coerced to string, integer, or floating-point datatypes as context requires.
 
@MichaelT You lost me at:
> This enables simple C code using goto statements to travel between (more or less) basic blocks.
 
One day, I will lurk on here at 4am on a Saturday and just say and check how long it takes for @Mat'sMug to respond.
4
 
> There are four unique things about Rail. First, the program counter in Rail is modelled as a train on a railroad, not as a free-moving pinball.
 
user55340
12:09 AM
$ 'main' (--)
 \  Read m and n as input. Just one number each for now
  \  Input is in the form "m\rn" where \r is a return character
   \-[Enter m: ]oi(!m!)[\n\]o-[Enter n: ]oii(!n!)[\n\]o-----(n)-(m)-{ackermann}-[): ](n)[,](m)[A(]oooooo--#


$ 'ackermann' (n m -- A(m,n))  A(m,n) = n+1             if m=0
 \                                    = A(m-1,1)        if m>0 and n=0
  \                                   = A(m-1,A(m,n-1)) if m>0 and n>0
   \-(!m!)-(!n!)-\
                 |
                 /
 
yeah i'm so over free-moving-pinball-based languages
 
Did you write the compiler for the whitespace language too?
Gotta run, going to do some video-editing for kindergarten, much more pressing issues there.
 
user55340
0
Q: FizzBuzz on Large Scale

user2577829So I was asked to create FizzBuzz at an interview... Easy enough but then they say what if there is a million data points. ie. divisible by 3 divisble by 5 divisble by 6 up until a billion. What is the best way to implement this. What data structure would you use? I was lost any help? EDIT: for...

 
I think with VBA I could write a loop that generates a method with a billion branches to a switch block (Select Case actuall), and then run that. Y'know, might as well.
 
0
Q: Undefined Function?

Doghouse308I am not sure why I am getting an error that game is not defined: #!/usr/bin/python # global variables wins = 0 losses = 0 draws = 0 games = 0 # Welcome and get name of human player print 'Welcome to Rock Paper Scissors!!' human = raw_input('What is your name?') print 'Hello ',human # sta...

 
12:20 AM
^^ borked
 
12:32 AM
where are the close-voters?
 
i vtc'd
 
@Phrancis you here?
 
maybe this will summon him: SQL MUSIC CIGARETTES
3
 
oh well
ah, thanks @Jamal!
 
12:50 AM
@Mat'sMug yes
 
Browsers!
I'll blame it on IE ;)
how's your foot?
 
Nah I've been on Chrome, took a few days off work! But I got about 1000 tabs open
It's deflated I guess.
I'm off that massive dose of antibiotics as of today, hoping it's all good from here
 
good to hear! I'm sure you drank to that! :)
 
Indeed, indeed
Been ODing on music lately, I've been tasked with making a song very eery and sinister sounding. Sort of like In This Moment but darker
 
lol my immediate thought was From This Moment (Shania Twain) - followed by WTF, and then "huh, what's that song?"
that right?
In This Moment is an American metalcore band from Albany, New York, formed by singer Maria Brink and guitarist Chris Howorth in 2005. They found drummer Jeff Fabb and started the band as Dying Star. Unhappy with their musical direction, they changed their name to In This Moment and gained two band members, guitarist Blake Bunzel and bassist Josh Newell. In late 2005, bassist Newell left the band and was replaced by Pascual Romero, who in turn was quickly replaced by Jesse Landry. Landry was replaced by Kyle Konkiel in 2009 and Konkiel was replaced by Travis Johnson in 2010. Jeff Fabb and Blake...
 
1:01 AM
More like it :)
 
never heard of
 
Pretty good band
NSFW though, mostly
Never imagined they had that many bass players... but then again, bass guitar is pretty easy. Guess Douglas Adams was right.
 
> bass guitar is pretty easy.
wut?
^^ you know Primus right?
 
Well, Les Claypool is in a different league :)
 
indeed!
 
1:08 AM
Fellow Canadian Geddy Lee is pretty good too
 
can't help but be awed @ drums whenever I see/hear Rush, but yeah :)
 
Yeah he's a pretty good drummer too ;p
 
(listening to some Primus)
have you seen the video they did with The Devil Went Down to Georgia?
 
Love the claymation style
 
@Phrancis exactly - best version ever!
 
1:20 AM
It's astoundingly awesome
 
We will be changing load balancers momentarily to test a configuration change, there should be no user impact.
 
I remember getting my ass handed to me on Guitar Hero 3 on the last song, though I believe it was a different cover
 
that specific version is my actual ringtone!
 
Had distinctly less awesome fiddle and more guitar
Holy crap
 
^^ the song is by some guy called ...Steve Ouimette!
 
1:26 AM
Hm. Sounds Frenchy.
 
doesn't it
 
0
Q: Merge sort in Golang

Samarth WahalI am just starting out with golang. I implemented the merge sort algorithm just to practice. Any suggestions or criticisms regarding the coding style? package main import ( "fmt" ) func main() { A := []int{3, 5, 1, 6, 1, 7, 2, 4, 5} fmt.Println(sort(A)) } // top-down approach fun...

 
Holy moly. Person on YouTube 100% on Expert. How many hours did they waste invest on this?
 
OMG my ugly C code with 2D array sum reduction works!
 
As of now, #stackexchange and #stackoverflow no longer support SSLv3 due to POODLE. You can read about it here: https://www.openssl.org/~bodo/ssl-poodle.pdf
 
1:34 AM
@Jamal you write ugly code?
 
It's for an assignment. :-/
I'm not sure if my method is what is desired, but it works and it adheres to the directions.
 
1:46 AM
wow
As stated, I am new to this language and was seeking advice from those who know much more than I do. Please forgive me for offending you — Doghouse308 12 mins ago
 
Does anyone know which section of the C++ standard talks about objects of the same class having access to each other's private data members?
 
that's nasty
 
@Mat'sMug what is? you mean friends touching each other's private parts?
 
at least in VBA they're explicit about being Friend before they play like that.
 
lol!
2
 
1:57 AM
anyone knows some basics?
 
How basic do you need?
 
@EngieOP section 11
 
I don't know python, but if it works like I think it might, you're calling game() before you define it - have you tried moving the # start game part below the def game() part? — Mat's Mug 1 min ago
 
@mjolka I was looking through Section 11, I can't seem to find it being explicitly stated.
 
A member of a class can be
— private; that is, its name can be used only by members and friends of the class in which it is declared.
i think that's it
 
2:04 AM
Okay, I kept re-reading that line. I guess it's not as explicit as I wanted it to be. Thanks.
 
np
 
@EngieOP it sounds pretty clear to me that private members are private members accessible only by the instance, and friends. It's the definition of "friends" you need to find I think
 
@Mat'sMug i think that's wrong
 
@Mat'sMug Thanks, I got it :)
I went to the Lounge and asked to be sure and got an answer.
 
2:15 AM
Kitty!
 
2:26 AM
0
Q: Another Solution to the Exclusive Queue Problem from the Little Book of Semaphores?

b16db0This page talks about the exclusive queue problem based on the "Little Book of Semaphores" by Allen Downey. Could my answer below be also valid? initialization: semaphore leaderMutex = 1; semaphore followerMutex = 1; semaphore leaderHasFinished=0; semaphore followerHasFinished=0; int numLeader...

 
OMG me and algorithms... I just did the most embarassing edit evah
 
1,1,2,3,5,....
 
@Mat'sMug the Lazy<T> isn't adding anything... in fact, i think it's a mistake
 
2:35 AM
is it?
 
Ummmmm, is the client or the server suppose to handle Paypal payments....
 
yeah, it was fine the way it was. except for the ugly b = a + (a = b);
 
@mjolka Main decides whether it wants the sequence lazy or not... isn't it more flexible that way?
oh wait
damn that whole answer is a facepalm
 
2:49 AM
Hmmmm
 
0
Q: Implementing Function that Maps over Stream

Kevin MeredithI implemented the following function: where the nth element in the stream (assuming the first element corresponds to n = 1) is the largest power of 2 which evenly divides n I'm giving it a vague name in the event that students try to cheat and search for it. foo :: Stream Integer foo =...

 
Well......
Apparently I can set the price I want to pay for this ;)
 
3:27 AM
Ahhhhh, god damn it.... Paypal is slow!
Btw, It didn't work :(
 
3:42 AM
Nice graphics ^^
 
good ad for glasses
 
4:15 AM
Oh I got another invitation to CastlevilleLegend ... ignores
 
4:52 AM
such graphics, much wow
 
0
Q: Wait, is this... LINQ?

Mat's MugContext I'm working on a little project that consists in a series of Microsoft Excel add-ins (.xlam). The code being submitted for review here, is located in the Reflection project: Feel free to comment on the project architecture, but I'm mostly interested in the Reflection.LinqEnumerable cl...

 
@Mat'sMug i don't know VBA, but it seems you're really pushing it to its limits. i'm impressed :)
 
Monking @all
 
ahoy hoy
 
hi
 
5:08 AM
1
Q: Command line Ceramic Capacitor Identifier

JohnI am an amateur programmer. I just wrote a simple Capacitor Identifier mostly to practice, i have not had many people review my coding and thought this would be a good time to start. It is completed and works. What i want to know, is there a better way i should have went about it? What should i l...

 
@mjolka thanks!
Good night CR!
 
night @Mat'sMug :)
 
@Mat'sMug I find your willingness to hack push the envelope with VBA impressive!
 
5:31 AM
Night @Mat'sMug
 
-2
Q: Need to understand the Instruction flow

VarunEvery post I see explains factorial or recursive functions that are one liners. I'm tired of trying to understand how the execution goes about in a function that has one or two recursive functions in them (specially trees). I ask you to explain to me how to write recursive programs when it comes...

 
TTGTB
 
@Phrancis down the rabbit hole :)
I'll probably hit the bottom soon...
 
next project: make VBA more like F#
 
hello
 
5:44 AM
hey @Aditya
 
2
Q: Greatest common divisor

FritosI wrote a program to find the greatest common divisor between two numbers. How do I improve this program? #include<iostream> using namespace std; int main() { int first_number; cout<<"Enter First Number : "; cin>>first_number; if(first_number < 0) cout << "Please enter a positive number" << e...

 
Night @Phrancis
Hello @Aditya
 
6:00 AM
Apparently, our english class is having a socratic seminar on pride and prejudice tmrw...

*procrastination intensifies*
 
hello @Dave
 
6:21 AM
@JaDogg Hello
 
6:33 AM
morning
 
6:48 AM
0
Q: Structuring a HTML5 Game without a framework

JohnAfter trying a couple different HTML5 frameworks, I've always found pure JS the most appealing. However, I am uncertain about the way I'm structuring it. Looking for advice, thank you! var titlescreen = new Titlescreen(); var fps = new FPSTracker(); var input = new Input(); var background = new ...

 
7:02 AM
Monking
 
Nothing more annoying than know-it-alls who like to announce they know it already every time the teacher brings something up
".. and this is how you create a web api response" - "but sir, you can remove that last else statement"
in a if(blaat) { return x; } else { return y; } snippet
Nothing to do with what was seen, nothing interesting either
 
@EngieOP Have you decided on a favourite? Elizabeth? Jane? Lydia?
 
0
Q: Design battle - Best approach for one line if else condition loop

MohanrajApproach 1: formattedTitle: (-> if @get('title') "City - #{@get('title')}" else "City" ).property('title') Approached 2: formattedTitle: (-> return "City" if not @get('title') "City - #{@get('title')}" ).property('title') Approach 3: formattedTitle: (-> title = "City" t...

 
7:21 AM
@200_success
Probably Elizabeth. She seems the most intelligent. I'm not finished with the book yet though.
googles even harder
 
7:44 AM
0
Q: More optimized approach of Dijkstra's algorithm

XegaraI need a graph-search algorithm that is enough in our application of robot navigation and I chose Dijkstra's algorithm. We are given the gridmap which contains free, occupied and unknown cells where the robot is only permitted to pass through the free cells. The user will input the starting pos...

 
> Remove Regions is another bulk action that will be particularly welcome by those of us who do not like the idea of regions in our code.
Yeah!
 
0
Q: better practice for Ajax long polling

ViPiNI'm using PHP,Mysql and Jquery for my project which has an instant notification area.I'm using ajax lon polling technique and this is the first time I'm using it. my jquery function is like this function get_notes(){ $.getJSON('get_notification.php','',function(data){ //dealing with reponse...

 
Now I can clean up the provided code by teachers more easily
 
8:13 AM
0
Q: Structuring a HTML5 game without a framework

JohnAfter trying a couple different HTML5 frameworks, I've always found pure JS the most appealing. However, I am uncertain about the way I'm structuring it. var titlescreen = new Titlescreen(); var fps = new FPSTracker(); var input = new Input(); var background = new Background(); var shops =...

^^ is this on topic ?
 
Breaks don't last long at work....
 
@mjolka what about create a linkedlist what contains prime numbers.
When the primenumber ends at 3 => change the 3 to fizz ends with 7 => buzz and when it's end with 37 => fizzbuzz, ends with 73 => buzzfizz ^^
 
urgh.. searching through the commit history for a usable commit for my project...
@JaDogg I think it is...
while he removed the init, the code in itself is sufficient IMO
 
8:37 AM
0
Q: CSV lookup problem solved with CoffeeScript

kharandziukSource code with some test: assert = require('assert') compile_csv_search = (text, lookupKey)-> [header, body...]= text.split('\n').filter(Boolean).map((el)-> el.split(',') ) col = header.indexOf(lookupKey) assert(col isnt -1) lookupIndex = body.reduce( (acc...

0
Q: Feedback on JSON C++14 library API/implementation

Vittorio RomeoI'm creating a C++14 header-only JSON library for fun, learning experience and to use it in my personal projects. I'm looking for feedback on: Its API/interface: since I'm using modern C++, I want the API to be as expressive and easy to write/read as possible. I also want it to be terse. Its ...

 
ermagherd.. last commit with the code that I am "fixing" for my project seems to be from almost a year ago...
and the commit-messages and the code look like total crap...
 
9:03 AM
Monking
 
Monking @all to which I didn't say monking in the meantime ;-)
 
0
Q: groupBy implementation in NodeJS

Dan PantryI came across a problem in my NodeJS app, which I solved by creating a method called groupBy - the purpose of this method is simple. Take an array, and a function which will select a field from an element in the array. Each element in the array should then be grouped based on this field and retur...

 
@JeroenVannevel Useless
Oh... is having one monitor not normal? ;)
I would love to have two or three or six
 
@skiwi No. No it's not.
I've got 3 right now but I could use one more
 
I"m just being jealous :)
Are that three monitors of decent size, or relatively small becuas eyou have three anyway?
 
I bought all 3 at different points in time without paying much attention to size or brand
but they're all 22"-24"
 
Must look... interesting, I'd buy 3 of same brand if I upgraded
You also use them while gaming?
 
9:28 AM
yeah, definitely buy the same ones
Yup
although I barely play any games anymore
but middle screen is game, left is music (youtube/spotify), right is chrome
 
I haven't had/made time the last month for sure
 
typically I have 3 chrome windows with each 2 tot 15 tabs on it open
What's stopping you from getting a second one?
The productivity increase is.. incredible
or you know, procrastination increase
 
Parents are stopping me... it's not fun
 
And physically the cabinet where my PC is located is stopping it, as only one screen fits literally
 
9:31 AM
JSON as XML
ah, that sucks
I've got 2 desks in an angle so while the top part of my first desk is now filled, I can continue on the second desk
 
Not ready for moving out either, so stuck with it for now
I will take revenge though when I move out eventually and buy at least three screens and show-off with them... evil grin
 
That'll show them!
 
@JeroenVannevel that is so nice
 
@Heslacher lol
 
9:36 AM
Also a great sentence:
Just because I can take a JSON document, HTML encode it, tunnel it with a SOAP envelope, BASE64 that into a Hidden HTML input, and and store it in a binary database column DOES NOT MEAN I SHOULD.
4
 
Good good, when I'm practically done with working on this Git branch, I can now finally remember it's name.
Spotify for Student with free Premium would be nice... not gonna happen though
yay, the Dutch government finally seems to get a basic understanding about how ICT projects work
 
10:13 AM
got an invitation for an AngularJS intro evening next week
Might not be a bad idea to attend
Since apparently we'll go through an 800-pages book on Angular the coming weeks in one of my classes
No trains at that time anymore, ofcourse..
 
0
Q: Parse prospero-Parameters

Peter RaderWould you guys check this code and give common suggestions or even testcases for junit-Tests? Sorry Docu is in German. /** * Gibt einen Prospero-Parameter aus der URL zurück. Dabei wird nur der Prospero-Part geprüft. * * @param url Die URL, darf nicht <code>null</code> sein. * @param name D...

 
10:37 AM
0
Q: for some of the inputs ,its exciding the time limit..what should i do?

Akashimport java.io.BufferedReader; import java.io.InputStreamReader; import java.util.*; class TestClass { public static void main(String args[] ) throws Exception { ArrayList<Integer> ar=new ArrayList<Integer>(); ar.add(2);int...

 
10:48 AM
Notice something odd?
gold badge, no silvers ;-)
 
Fanatic?
 
Reversal ;-) +20 on a -5 post.
20
A: Closing the Vi/Vim Proposal

rolfl@shog9 suggested I put together a list of questions scattered around SE that would have been successful on a vim.se site. Part of the motivation for this is that it has been suggested: Shog9: The best argument for splitting off a topic is that there's no single site where the entirety of it i...

 
It's the first time that I see a question generate 7 reversal badges at once.
 
0
Q: Is this code readable?

ReviousThe first part of code is for me very unreadable. I tried to write in another way but I'm open to your suggestion! return ViewData.ModelState.FirstOrDefault(x => x.Key.Equals(parameterName)).Value != null && ViewData.ModelState.FirstOrDefault(x => x.Key.Equals(parameterName)).Value.Errors.Any(x =>...

 
10:51 AM
@CaptainObvious Is this title good?
 
@Vogel612 Is this comment relevant?
 
the answer to all these questions seems to be no..
 
Oh, there is a new LifeHack.SE proposal. How come?
 
11:26 AM
Now it can go hot:
0
Q: To space " " or not to space ""

ReviousThe first part of code is for me very unreadable. I tried to write in another way but I'm open to your suggestion! return ViewData.ModelState.FirstOrDefault(x => x.Key.Equals(parameterName)).Value != null && ViewData.ModelState.FirstOrDefault(x => x.Key.Equals(parameterName)).Value.Errors.Any(x =>...

 
@JeroenVannevel What, there's no evening trains in Belgium?
For some reason I'm tempted to make a GPU-accelerated Sieve of Eratosthenes in C++
2
> Do you know anyone that bought the video game Halo, or Myst, then proceeded to open the box and read the manual before playing the game? Whoa there guys, we can't play the game yet, we gotta read these instructions first!
I used to do that, had to do something when going home after buying a game with my parents!
 
11:44 AM
Same
 
Remember, there were no smartphones yet back in those days
 
0
Q: display subcategories of selected category in tabular form

user3732711I have a form that has two parameters amenities and attributes. The amenities parameter has a dropdown menu that whose value gets populated from a separate table. The second parameter is attribute whose value will be entered by the user and will get saved in a database. View of database will be: ...

 
I see these questions and feel stupid ;)
 
12:09 PM
0
Q: Method returning IEnumerable<T> should ToList() or not

user2000095-timI can't decide whether my method that returns an IEnumerable should itself be lazy or whether it should build a list and return that. I often opt for the latter so I can be sure the enumeration of each value isn't performed multiple times. For example: public IEnumerable<UserProfile> GetUsers() ...

 
12:39 PM
@rolfl Aaaaaand the title is gone
Hi everyone!
 
Monking @Marc-Andre
 
And @Phrancis you're sick or something ? (reading the starred things)
And hi @Vogel612 !
 
Hi!
 
Hi!
 
Hi!
 
12:53 PM
Hi!
 
I have the feeling that the 2nd monitor's description didn't change since my first visit here.
 
@Morwenn And it will probably remain the same forever ;)
 
Description -> General discussion about Code Review
?
Yeah, it didn't change :p
 
tags...
 
12:57 PM
is a more "recent" addition
 
Description -> "Come drink coffee with us" would be an improvement.
3
 
looool
ignore-the-trolls is obsolete (at least in respect to a certain dictator)
and it should be
 
I don't feel like I'm being ignored anyway.
3
 
lol
 

« first day (529 days earlier)      last day (3487 days later) »