« first day (936 days earlier)      last day (3088 days later) » 

8:15 AM
possible answer invalidation by 200_success on question by azngunit81: codereview.stackexchange.com/posts/111760/revisions
 
8:38 AM
 
@VinodMadyalkar you're aware you're talking to two prominent members of the Code Review community? — Dan Pantry 19 secs ago
 
Which is a point.. @Phrancis, why is that code off topic?
I'm not sure it is
It might not receive many interesting reviews, but I don't think its OT
My graphics card is being delivered by Yodel, so I'm expecting it to end up in a ditch somewhere. :(
 
@Stultuske Not really - if you want a code review, there is codereview,stackexchange.com. — assylias 36 secs ago
 
@Duga false positive, though wtf, OP asked a question then self-answered within 15 minutes
its almost as if he asked a rhetorical question lol
 
Welcome to Stack Overflow. This is a wall of text. You didn't even explain why your code is not enough efficient for you. This is an off-topic question for SO and I'm not sure it will be welcomed in Code Review as well. Please read FAQ, How to Ask and help center as a start.. — Soner Gönül 54 secs ago
 
9:03 AM
This question is off-topic on Stack Overflow. Maybe you want to ask a similar question on Code Review. — Hexaholic 22 secs ago
 
9:13 AM
0
Q: Tips and thoughts for this Google oAuth Angular service

J. DoeThis is the whole working module: angular.module('gapiOAuth', []) .controller('gapiOAuthController', ['$scope', function($scope){ }]) .factory('gapiCredentialsSrvc', function(){ return { gapiClientId: 'xxx', gapiScopeUrl: ['https://www.googleapis.com/auth/u...

 
If the code is working, try Code ReviewPeter Wood 7 secs ago
 
There is a game on XKCD. xkcd.com
so many lost hours will be had today.
 
Zak
@DanPantry Spoiler Alert: There's a Star Destroyer
And a secret Volcano Lair
 
9:29 AM
Amazingly it's all written in what appears to be plain old javascript using the DOM.
 
possible answer invalidation by WagoL on question by WagoL: codereview.stackexchange.com/posts/111812/revisions
 
0
Q: LINQ queries improvement - repetition of query

AgramerI have a DAL class full of LINQ queries which I would like to improve as I found that I'm repeating myself couple of times. As you can see the part below is repeated couple of times and I was wondering if it is possible to reduce the number of repetitions (passing the query somehow?) and/or imp...

 
Monking
Mobile chat looks better with the New Design
 
9:49 AM
Monking all
Looking nice today
 
monking @Vogel612 and @SuperBiasedMan
 
Zak
Well this is fun. I've been asked to research another potential acquisition target. Only this time, there is nothing on the internet. I can verify that it exists. That is literally it.
 
Monking
 
Zak
No company accounts, no website (seriously, who doesn't have a website these days?)
 
It's a trap!
 
10:00 AM
@Zak If they have no internet presence there's no "potential" there. They are not a viable acquisition target.
Whether due to technical or willful ignorance, it is not a good sign
 
Zak
As I understand it, it's an old (soon to be retiring) Financial Adviser. So it's not unheard of for such one-man-bands to have their book of personal clients and that's it.
 
@Zak that's true, my grandfather ran an insurance company known as Shiregem and didn't have a web presence.
However the insurance company crumbled precisely because he didn't have a web presence.
 
Zak
But to have no records anywhere (even official ones) requires a special level of antiquatedness
Oh, wait, I found their website.
 
This is the only web presence my grandfather had. :s
 
Zak
 
10:03 AM
Is having a chat with the owner an acceptable method?
 
Zak
@Mast Our director will be doing that at some point
this is background research
 
Can't you pull their FCA files?
 
0
Q: How to reduce if-else usage for multiple conditions and return error messages?

sky91This is a program to read and store the data from a excel file(.xlxs) which is uploaded by users. My questions are 1. Any better approach to reduce the usage of if-else to return the error message? 2. How to design or construct a good coding pattern before I code? What kind of aspects I should p...

0
Q: Clean call api from client, with good practice

merso0027I am working on architecture where I can have any client + server api. I need to call api as clean as possible and get,post,put.. ani object I want to. So - for me is importnat to have clean secure code with good practice. This is how i implemented and I would like you to help me to improve this...

-1
Q: ATM BANK USING JAVA PROGRAME

MIKE PEREZMost of you have bank accounts or you have ever withdrawn money using ATM, Centenary bank is looking for programmers who can design a small ATM transaction software using java. Use if conditions and loops Tasks. a). Create a program to display three operations for the user (like a menu) e.g ...

 
Zak
@Mast I have
and their Company House Accounts
No meaningful information. Zip. Nada.
 
@CaptainObvious HAMMERTIME!
@Zak Well, at least it gives an indication about their size and profitability. It's a start.
 
Zak
10:06 AM
@Mast Yep.
 
@Mast I like how someone replied with the link to "how to ask"
 
My business just became one of the 3 trusted credit giants in the UK :-)
big times ahead
 
@SuperBiasedMan I don't. Link-only comments get flagged instantly by me.
 
Zak
@DanPantry Nice.
 
ooh damned I can't even close a question anymore
 
10:13 AM
Welcome to the little boys club.
 
Seems Like I need 70 rep to have the rights
 
I thought you needed 3k for VTC rights?
 
@Mast yeah it looks now lik ethat
@Mast indeed, I'm at 2930
 
153 rep away myself.
 
@Mast oh bugger
 
10:15 AM
I'll look for a question to answer in a few minutes
 
I guess it is time for me to start reviewing :(
 
Yeah I'm glad I had a long quiet period at work to get me to 6k, all I'm really missing are less important delete votes. I'm missing more from not seeing deleted posts to be honest.
 
Since this is working and you just want feedback and suggestions you could think about putting this on the Code Review site. Take a look at the site's how to ask page. — SuperBiasedMan 34 secs ago
 
133, thanks Santa?
@SuperBiasedMan Agreed.
 
My graphics card still hasn't left the depo. It's meant to be delivered before 12pm. :s
 
10:22 AM
I could VTC questions which were at least 2 days old IIRC (almost never needed that, we have an active community).
 
@Mast now on 3k?
btw, thx also to santa
 
And I'm just shy of 14k away from full deletion privileges...
 
lol,, I can't help with 14k rep in one time ;)
 
How hard can it be? That's just like, 28 bounties.
 
If your code is working, this question may be better placed at Code Review SE. — πάντα ῥεῖ 52 secs ago
 
10:26 AM
then they are high bounties
 
@SuperBiasedMan 280 bounties
28 * 50 = 1400, not 14000
 
Bounties can go up to 500 points ;)
 
can
just like someone on a dating site can message me first
doesn't mean they will :p
 
@DanPantry Hey, not so negative!
The chances of you being approached on a dating site are probably higher than @SuperBiasedMan stumbling on a 500 points bounty.
6
 
10:32 AM
There's plenty more bounties in the sea Dan
 
@Mast 1/115 chance to be swiped right on Tinder - that's not including being replied to, which is even lower ;-)
 
Monking
 
Speaking about bounties and voting trains, this answer really deserves more upvotes. I already put a bounty on it it so I did what I could:
6
A: VHDL mux in need of generics

PaebbelsThere are 4 ways to a solve this: Solution 1: You can define a fixed width STD_LOGIC_VECTOR (SLV), which can be used to construct other vectors (let's call them STD_LOGIC_VECTOR_VECTORs (SLVV). subtype T_SLV_8 is STD_LOGIC_VECTOR(7 downto 0); -- define a Byte type T_SLVV_8 is array(...

That guy went above and beyond.
 
4 different solutions is pretty nice.
 
And all good ones. Nothing half assed in there.
This reminds me of CR in some way:
 
10:40 AM
Meh, this university sucks, at least this course sucks
I maybe didn't put 100% motivation in it but they gave me a 4 (out of 10) for motivation, which suggests that you did nothing at all, it's worth at least a 5... For the report we got a 6 and both parts count 50%
 
Wut?
 
I can see this teachers problem though, if he gave me a 5 for the motivation part I'd have passed this course, and he appereantly dislikes me, so he didn't want that
 
Can you appeal?
 
writing a review
^^
 
I think there's enough ways to appeal
 
10:42 AM
@chillworld At work at the moment, I'll find a question to review later today. Only 106 points to go, that's about one good answer.
 
I could discuss with the teacher, then I could complain at my study coordinator and lastly I could complain at the exam committee, I could opt the exam committee to look into changing to a different course, there's no way I'll do this one again
 
I have found a zombie, good upvotes and no answers
 
Sounds like you got letters to write.
 
But I haven't even received a resit proposal yet, normally for regular subjects you get a resit, so I would guess for a project you get it too
 
Python 2.7 and C++ zombies are hard to find, those around are often out of my league.
@skiwi Projects may well be special.
 
10:44 AM
Funny thing is that the "project resit" is in this quartile which is ongoing for 3 weeks already because they graded the project so late, so now way I can join that one
 
@Mast Same. The Python zombies are usually because of solid code that's hard to fault/niche technology use that I know nothing about.
 
0
Q: javafx await implementation

GroostavI'm debating trying to take a crack at getting something similar to C#'s async-co-routine like nature over on javaFX. This is technically feasible since the Quantem toolkit exposes the enterNestedEventLoop and exitNestedEventLoop methods, but using them is tricky. If you haven't seen it, C#'s a...

 
I've written in a lot of languages, but I don't deem myself proficient enough in most of them to review them.
 
Ooooooh, a new design :o
Beta blue colour choice though x)
 
This question should be asked on Code Review. — Paebbels 55 secs ago
 
10:58 AM
0
A: Refactoring a top-level singleton class as an inner class?

chillworldPublic class, private Interface? I'm pretty confused by this setup. The meaning is always trying working towards the most highest object( this case interface) possible. I'm thinking that you created this setup so having the keys as constants. But there is nothing wrong to have those keys as priv...

dinner time
 
No Code Review mugs? :(
 
@Morwenn @Mat'sMug ? ;-)
 
@DanPantry It's a trap, it's not written Code Review on it :p
 
Zak
@Morwenn Who knows. As I understand it, swag may/may not be a standard list of items and if not, who decides what they are is unclear.
 
@Zak A mug would be fitting though.
 
Zak
11:09 AM
@Morwenn Also, Rubber Ducks :)
 
Maybe the rubber duck is also a mug
 
didnt Mat work on Rubberduck?
The plot thickens.
 
Rubber Mug
6
 
Would producing own swag violate copyrights?
Welcome @AmazingDreams
 
Ok, I wouldn't like to drink in a rubber mug.
@Mast If you explicitly wirte « Code Review Stack Exchange » on it, then probably yes.
 
Zak
11:14 AM
@Mast *NARL: The words "Code Review", probably not. The words "Code Review" which in any way resemble or imply SE's trademarked logos, YES.
 
@Zak Is the CR logo itself trademarked?
 
Zak
@Mast I'm pretty certain the beta-blue version is
And, obviously, the new one
 
Next question: Would they care?
It's not like we're competing with one of their shops. They don't have shops.
 
Zak
@Mast Whether or not they cared, you can reasonably assume they would try to shutdown anything they became aware of.
 
Just a logo with "Code Review" under it on a mug, for example.
Meh, time to go anonymous then I guess.
 
Zak
11:17 AM
So, you could do it, just organise it in a non-SE chatroom, do a private bulk order and handle individual payments/shipping yourself
As soon as you make a link/payment portal, that's something they can sue you for.
 
Yea, that would be a bad idea.
 
Zak
Once people actually have the stuff, I doubt they'll sue anyone for possession
 
Do it the "If you happen to send me cash, I could happen to send you some stuff, but we don't call it a payment"
 
Zak
@Mast That's how I would do it
For extra protection, make sure not to make any kind of profit.
 
Of-course, I'm not planning to get rich over SE's back. I just want people to get mugs if they want to.
 
Zak
11:37 AM
I'm not sure what I like more, The guy thinking "Hmmm. Ants on stilts, why not!", the guys who funded it, or the guy whose job was "put 25 ants on their backs and glue stilts to their legs"
 
Turning ants into spiders...
I always thought they moved based on smell.
Stiff their noses and they're blind.
 
If the code works, it's off-topic for Stack Overflow. "How can I make this WORKING code [neater|shorter|faster|tidier]" questions belong on codereview instead. — Adam Smith 17 secs ago
 
@Duga With some changes, yes, it should go here.
 
If you decide to move the question to Code Review, make sure you include the code in your question. Code behind links is unacceptable over there. — Mast 47 secs ago
 
My SO question is turning into a zombie at this pace...
2
Q: Shared variable among parts

MastI have multiple parts based on the same length. If the assembly is 400mm wide, part1 is 200mm, part2 is 180mm and part 3 is 150mm. It would be great if I could declare the length of those parts as (respectively) al-200, al-220 and al-250 (where al is the length of the assembly). Can I store this...

Interesting MSO post:
21
Q: To curate or to not curate - questions about code-only answers

Vogel612There's ample evidence of previous discussions about Code-Only answers, which all reach the (reluctant?) consensus of code-only answers being acceptable (as in shouldn't be deleted), but up for downvotes. So why am I bringing this up? I hope to solve or at least mitigate one or more of the foll...

 
Zak
12:01 PM
@Mast Depends on the ants. In this case, it was desert ants
 
12:39 PM
mhh 30 more rep to go
I'll look for another question to answer
 
Eh~, it seems that the so-called exact sort as implemented is not exact. It could perform less swaps :(
 
0
Q: Which loop to use for multiple if statements which serialize objects

Darren EstcourtI have figured out how to serialize multiple objects, however I am utterly convinced I can use some kind of loop for the if statements below, to avoid duplication. Please can someone advise how I would do this? I have 20 objects in total, this code snippet shows the "if statements" for 4 of them...

0
Q: Guessing Game in C (help me)

AnnaWrite a C program that is randomly generates a number between 1 and 15, and then the user is asked to guess that number. The game gives the user three chances to guess before user loses. In case the user lost, program gives user the option to play again (user chooses 1 to play again or 2 to end t...

 
Oops, wrong chat, sorry.
 
@CaptainObvious gimme the codez
 
12:56 PM
-1
Q: Writing Files - Number list program

PortableGibbonthis is my task - Create a program that accepts a list of numbers from the keyboard. Once the user finishes inputting numbers all those over 10 are written to a file called “largeNumbers”. I have started to code but my code is an absolute mess and I have no idea where to start, I would really app...

0
Q: A simple PHP login system

JimmyI'm super new to PHP and I'm trying to get a functional login system together. This is the code I have: class/user.php <?php class Users { public $username = null; public $password = null; public $salt = "Zo4rU5Z1YyKJAASY0PT6EUg7BBYdlEhPaNLuxAwU8lqu1ElzHv0Ri7EM6irpx5w"; pu...

0
Q: Running multiple games concurrently with node.js

GuestI am currently creating multiple games by adding objects of type Game as properties of an object called games. The names of these properties are set programmatically - for example, the first game will be a property of games called game1. Sockets joining this game will join the room room1. Is thi...

 
I'm voting to close this question as off-topic because working code for review may be more suitable for codereview.stackexchange.com. — chepner 21 secs ago
 
@Morwenn Taking a shot at improving it?
 
@Mast I can try but it would be a different algorithm in the end.
I think I know how to make it perform the least possible amount of moves, but it takes some memory.
 
Given how cheap memory is nowadays, I think using slightly more memory to achieve less swaps is worth it.
Sure, not on embedded platforms, but on desktops and laptops definitely.
 
1:12 PM
@chepner: Thanks a lot. I was not aware of this codereview site. I will delete/close this question and move it to that site. — BaRud 58 secs ago
 
0
Q: graph depth first search and breadth first search with iterator (java)

guilhermeI have this class GraphDirListAdj. I need to change traversalDepth(E orig) and traversalWidth(E orig) to use Iterator with the following "classes" (interfaces): interface Iterator and IterableGraph. How can I do? public class GraphDirListAdj { private ArrayList<Node<E>> lNodes = new ArrayList<...

 
@Mast No, I mean it can grow up to O(n) memory because I store positions.
 
@CaptainObvious Is it breadth-first or depth-first? You can't do both at the same time!
@Morwenn If no proof of concepts exist, you could make one anyway to show the exact difference.
 
codereview.stackexchange.com/questions/111905/… is the same question at proper place. — BaRud 44 secs ago
 
@Mast This is what I'm doing. It should be a sorting algorithm with at most 3/2 * (n - 1) elements moves.
 
1:18 PM
Please explain your answer. An answer like this will only attract downvotes while your intentions are good. — chillworld 13 secs ago
pffft
he gets a downvote at 15:00 if not edited
 
@chillworld Downvote now, reverse it at 15:00 if he has edited.
 
mhh and thinking that the question is off topic also
last sentence : how can I do it?
 
Agreed.
Anyone with close-vote powers around?
 
@chillworld too late
@Mast sure ;-)
casted my vote
 
@Mast almost ^^
 
1:22 PM
0
Q: proper way of writing a python code

BaRudThis is about writing a better code. I am not much experienced in python, just write some small script. All my codes are procedural. They works fine, and I always check them with pep8. An example is: #!/usr/bin/python3 import os import sys import numpy as np import scipy as sp import scipy.opt...

 
If I don't get rep quickly I'll go for double Marshal
 
Monking!
 
monking @Phrancis
 
1
Q: simple password generator

user90614Here is simple password generator on Java. public class PasswordGenerator { public static final String LOWER_CASE = "abcdefghijklmnopqrstuvwxyz"; public static final String UPPER_CASE = LOWER_CASE.toUpperCase(); public static final String DIGITS = "0123456789"; public static fin...

 
Wow this is so weird... I'm literally alone in the building at work today
 
1:36 PM
Isn't it Thanksgiving?
 
It is, indeed
 
No work today, @Phrancis
 
I'm scheduled to work, so are several others on my team, but eh, guess everyone else decided to work from home
 
@Phrancis Why are you at work?
Did you draw the short straw?
Don't get me wrong, I like having the building for myself. Almost never happens since there's not much variation in the working hours possible here, but still.
But last I checked Thanksgiving was kind of a big deal in the USA.
 
There's supposed to be 6 of us just on my team today lol
> That’s why we have to provide coverage during the holidays…. Because the patients still need care. Thank you for working the holiday time.
 
1:44 PM
Ah, healthcare.
Yea, that explains it.
 
Ok, now what I have looks like an exact sort.
 
If the database crashes on a holiday it still needs fixing.
@Morwenn Are you putting it up for review?
 
@Mast I may be. I will clean it first. In its current state, it's horrible and position-based instead of iterator-based :p
 
Good. We could use more good questions.
 
damn, it's for tomorrow answering the next question. (and I just found a nice one)
 
1:47 PM
@Mast Sorry for not being there anymore :/
 
^^
 
But now that I code for an actual project, I feel less like reviewing code.
 
Hey, don't worry about it. People come and go (and hopefully come back).
 
Well, I do review code since I'm stealing code from open-source projects and enhancing it to meet my library's standards.
And when it makes sense, I do a bit of additional work to create a suitable pull request for the original project.
 
Good to hear you're still busy :)
 
1:52 PM
@200_success don't get the regulars free goodies for the graduation ^^?
 
@chillworld Only if your rep is high enough.
 
Huh, null pointer exception
 
Usually.
 
class Main {
    static Clock clock;
	public static void main (String[] args) throws java.lang.Exception {
		System.out.println(clock.instant());
	}
}
 
@Mast hey almost 3k rep ;)
@Phrancis your clock isn't instanciated
 
1:53 PM
Oohhhhhhh DUH
 
lol
 
That's new
Main.java:7: error: Clock is abstract; cannot be instantiated
    static Clock clock = new Clock();
                         ^
 
abstract class need an implementation
so new Clock () {}
and of course implement abstract methods if there are any
 
Zak
@Mast I know a guy who got into IT 20 years ago, once earned $20,000 for coming into work and fixing a server on christmas day. Worked out at $10,000 an hour.
2 Hours later: "Wow, I'd forgotten how long writing a review can take."
 
@Zak Good, he probably deserved it. Servers dying on you can cost a lot of money for a company.
On an unrelated note:
@CodeCaster, how can we prevent users from answering uninteresting questions but letting them vote to close instead? We can't. It's too late. Users now routinely answer crap questions, upvote those questions in the process, upvote their answers among themselves, and stand up to anyone trying to convey the idea that bad questions should be closed and not answered. I'm starting to believe there is nothing we can do about it anymore. — Frédéric Hamidi 23 hours ago
 
Zak
2:00 PM
I spent half my gap year working in a kitchen. Had to do 10 hours Christmas day. Got paid a whole £90.
 
Yea, the world isn't fair.
Ooh, my 3rd Enlightened badge just came in :)
 
@Mast gratz
I'm thinking @Phrancis his clock is working now :)
 
I decided to go with LocalTime instead of Clock, which seems far simpler to use :)
 
@Phrancis joda time?
 
@chillworld Huh?
 
2:09 PM
@Phrancis leave it ;) joda time has also such class (and if you use java 8 I'm not sure but isn't joda integrated there?)
 
Zak
This code Is the easiest code to follow/understand I've read in quite a while. Deserves more upvotes.
 
@chillworld The real question is "who is joda?"
 
possible answer invalidation by sky91 on question by sky91: codereview.stackexchange.com/posts/111881/revisions
 
@Phrancis a little green guy you can see in star wars :) : joda.org/joda-time
joda time was a dependency what was better then Java build in Date stuff
 
Ah ok
 
Zak
2:11 PM
@Duga Seems ok.
 
@chillworld That was Yoda
 
Call me masochist, but I think I kind of enjoy working with DateTime stuff, overall
 
@Mast ah damn, it was close :)
 
@Zak No, it doesn't. He cross-posted.
 
Zak
2:13 PM
@Mast Well, he was pointed in our direction
 
@Phrancis and read the comments below
 
@Zak Usually you migrate instead of cross-post.
 
Zak
@Mast Considering they're completely new to SO and CR, I think we can be a little forgiving, no?
 
Did it with JODA, performance optimized by at least 65 percent! Cheers mate! — Skynet Aug 8 '14 at 12:40
 
but TTGH
 
2:15 PM
What about posting this to Code Review ? — LeFlou 59 secs ago
 
Zak
Also, this question was heavily downvoted due to being Off-Topic. Seeing as the OP cleaned it up and made it a reasonable On-Topic question, deserves some Upvotes.
 
@RubberDuck I could lie and say that I thought it was a good practice, but the reality of it is that it is what I'm used to at work, and I wrote this to teach to a friend who wanted to apply. But yes I agree, it seems redundant. On the flip side, at least it makes table aliasing easy lol. — Phrancis 18 mins ago
Lol @Phrancis. Happy turkey day cuz.
 
Found a misspelling in a title of a hot topic on the english language site. Feels extra inappropriate there.
 
I log in, annnndddd I stared the whole wall.
Morning!
 
monking @TopinFrassi
 
2:27 PM
Morning @TopinFrassi!
 
In the end, my exact sort takes O(n²) comparisons and O(n) auxiliary memory.
 
Morning!
 
OMG why are there so many different ways of doing dates and times in Java
 
0
Q: Returns two elements from a list whose sum is a target variable

Vipin Raidef search(a,b): for d in b: if a==d: m=True break else: m=False return m x=[1,4,5,7,9,6,2] target=int(raw_input("Enter the number:")) for i in x: if i<target: pair=int(target)-int(i) in2=search(pair,x) if in...

 
The java.time package seems to be pretty good, apparently it is inspired by joda
 
2:39 PM
@Phrancis The 1.8 one yeah...
@Phrancis OMG why are there so many different ways of doing anything in Java! (FTFY)
 
0
Q: golang return different kind of values?

rogerI have similiar codes as follow: func getPro(cvId string) (coll *mgo.Collection, r *cv_type.CvProItemMeasure, err, error) { session := this.session.Clone() defer session.Close() obj := &cv_type.CvProItemMeasure{} err = coll.Find(bson.M{orm.CV_ID: cvId}).One(obj) return obj ...

 
You should have posted this on Code Review because "Best" can't be answered. One thing I will say though is that you need to use the If Operator instead of the IIf function — Matt Wilko 16 secs ago
 
Zak
3 answers in the last 24 hours, that's the same as in the last 2 months ^^
 
0
Q: Async db repository

teebotThis is a simple repository where I want to save all the invoices of some queried users. I wanted this module to only expose a simple saveInvoices method and return a Promise. As a DB, I use Firebase whose API is async but does not return standard JS promises so I promisify the db queries. I h...

 
2:50 PM
This is just play code, but does this make any sense?
class Main {
    private static LocalDate date;
    private static LocalTime time;
    private static LocalDateTime dateTime;
    private static ZonedDateTime zonedDateTime;

	public static void main (String[] args) throws java.lang.Exception {
	    final String NEW_LINE = System.getProperty("line.separator");
	    String output = String.join(NEW_LINE,
	        String.format("The current time is %s", time.now()),
	        String.format("The current date is %s", date.now()),
	        String.format("The current date-time is %s", dateTime.now()),
Mostly curious if my way of building the multi-line string will get me hunted down
Trying to print to console as few times as possible, since I hear it's a fairly expensive operation
> The current time is 14:49:34.573
The current date is 2015-11-26
The current date-time is 2015-11-26T14:49:34.580
The current zoned date-time is 2015-11-26T14:49:34.580Z[GMT]
 
the NEW_LINE variable is pointless (same reasoning as a few days ago)
I would just print it out directly. There's not really any use to concatenate things here
 
Oh, I could just shove System.getProperty("line.separator") right in the String.join couldn't I?
 
then you can use System.out.printf() and omit the String.format()
 
(if I was going to use that method)
 
2:55 PM
Cool, that works
 
I'll pretend you didn't doubt my awesomeness
3
 
lol
@JeroenVannevel Classic X/Y problem. What I really wanted to do is a multi-line string, which Java still doesn't support for some obscure reason
So String.join() seemed more readable and less clunky than "Str1" + "\n" + "Str2" etc
 
C# does support it
just pointing that out
 
Pretty much everything does, except Java
Groovy has multiline strings, along with string interpolation, which would make the above a breeze to write
 
codereview.stackexchange.com This might be a better place to ask for this kind of question. — Qirel 49 secs ago
 
3:03 PM
I don't think C# has string interpolation yet, or does it?
 
It does.
@Phrancis Does it merge adjacent string literals?
 
graphics card arrived. :D
 
@EBrown just made a question because of that question
yesterday, by EBrown
@Mat'sMug Is there an easy way in .NET to split a string into an array by pulling chunks of the text in. I.e. I have an 18 character string I would like in 3 6-character pieces.
 
0
Q: Imacros If Text Exists Then Press Button

user3541576I'm trying to create a script in imacros that when it recognizes a word in a line of text "images" that it will then execute a click on a div or button. This is what I have so far: TAG POS=2 TYPE=DIV ATTR=TXT:Select<SP>all<SP>images* EXTRACT=TXT SET !VAR1 EVAL("var text=\"{{!EXTRACT}}\"; if (tex...

0
Q: Split a string into chunks of the same length

HeslacherInspired by this question in chat Is there an easy way in .NET to split a string into an array by pulling chunks of the text in. I.e. I have an 18 character string I would like in 3 6-character pieces. I thought that ain't be that hard. I would like to get any thoughts and improvements yo...

 
monkevening
 
3:10 PM
hey @Quill
 
possible answer invalidation by matt95 on question by matt95: codereview.stackexchange.com/posts/111749/revisions
 
nice design looks sexy :-)
 
Zak
@Duga Probably against the rules in one way or another
 
@Morwenn Java? I think it only merges if you manually concatenate them with +, or you use another String function like I am doing
 
IT'S SNOWING!!!!
(In Minnesota)
 
3:20 PM
With Groovy I could just do
String output = """The current time is ${time.now()}
The current date is ${date.now()}
The current date-time is ${dateTime.now()}
The current zoned date-time is ${zonedDateTime.now()}"""
 
@Phrancis Ok. I wasn't sure :)
 
This question is really off-topic for Stack Overflow. Perhaps CodeReview but check their guidlines first. — Paulie_D 11 secs ago
 
It seems that my exact sort fullfills it promises: it is super slow and performs a lot of comparisons, but it still performs less move operations than a selection sort.
 
Unclear. What works ? What doesn't ? Or are you looking for code review. PLease edit question or post to codereview.stackexchange.comkebs 5 secs ago
 
@Phrancis I'm pretty sure thats normal concatenation surely?
Which is why you're meant to use StringBuilder and not +
Welcome to 2nd, @Laf :-)
 
3:30 PM
@DanPantry Yeah, I'm trying to move away from just concatenating stuff together and instead using stuff that's designed to do that
 
@DanPantry Sometimes concatenation will be optimized to use StringBuilder still a good thing to do though!
 
@Marc-Andre I prefer to not rely on compiler optimisations given that you could be compiling on different machines - CI, for example
imo compiler optimisations are a bonus unless they are guaranteed (see inlining)
 
@DanPantry Shiny, tell us whether it lives up to your expectations when you've installed it.
 
@Mast I shall. It's huge..
 
@DanPantry I agree with you!
 
3:34 PM
@DanPantry That's what I thought when I received mine years back. Hence the creative placement.
 
@Mast lol
I don't mind bashing the case around a bit... I want to get a new one anyway
would rather break the £30 case than the £250 GFX card
 
Exactly.
And with the fans on those things dust isn't much of a problem in my experience.
 
1
Q: Site rooms button hover color hides the logo

Marc-AndreWhen I hover the site rooms buttons, the hover color is the same as the logo color which make it invisible. Maybe we should find an alternative color for it ?

 
To give you an idea of size (I have size 9 feet)
 
Nicely formed first post. Alternatively, could have posted on codereview.stackexchange.com It is borderline which would be best: here or there. — chux 7 secs ago
 
Laf
3:49 PM
@DanPantry Thanks ;) I was just droping by to look at the new design ;)
 
it's pretty sweet
 
@DanPantry Is it the GTX 970?
 
@skiwi Yes (never mind the fact the box says "970)
 
Right, after that you had to post a picture of the box where it says GTX 970 :P
 
Ah, one of these days I'll buy a gaming PC
 
@Phrancis be careful its expensive. that card alone cost me just under 350 euro
(but it is also a top-of-the-line card, only exceeded by the Titan range by nvidia and some AMD cards)
 
My PC is a gaming PC. It cost about $2k with accessories.
 
@DanPantry Also exceeded by the GTX 980 and GTX 980 Ti though, but they are a tad more expensive
 
I just play the more indie games, so I've never needed to get a good graphics card. I only went over 1k on a macbook once (not for gaming purposes).
 
@skiwi s/tad/600 euro each... the gtx 980 is double the price of the 970 xD (source)
 
3:57 PM
MacBooks <3
 
Accessories were Office 2010 Pro (which was a deal because I got Office 2013 Pro free) and a 3 year extended warranty.
 
@Phrancis :o
 
I do want a macbook, though
Gaming PC != laptop on the go
 
I miss it so much
 
It was worth every cent, though. And my screen got a problem with burning in it, so I have a spare screen downstairs that I never installed.
 
3:59 PM
@DanPantry Oh ouch, that's a bit too much
 
I've had my regular old MacBook which I paid USD $900 for, since about 7-8 years ago. Still works good, never had anything really bad happen. Probably will replace it soon with a newer MacBook, since it is getting a bit slow considering newer software
 

« first day (936 days earlier)      last day (3088 days later) »