|
1. The lounge is for the CodeProject community to discuss things of interest to the community, and as a place for the whole community to participate. It is, first and foremost, a respectful meeting and discussion area for those wishing to discuss the life of a Software developer.
The #1 rule is: Be respectful of others, of the site, and of the community as a whole.
2. Technical discussions are welcome, but if you need specific programming question answered please use Quick Answers[^], or to discussion your programming problem in depth use the programming forums[^]. We encourage technical discussion, but this is a general discussion forum, not a programming Q&A forum. Posts will be moved or deleted if they fit better elsewhere.
3. No sys-admin, networking, "how do I setup XYZ" questions. For those use the SysAdmin[^] or Hardware and Devices[^] forums.
4. No politics (including enviro-politics[^]), no sex, no religion. This is a community for software development. There are plenty of other sites that are far more appropriate for these discussions.
5. Nothing Not Safe For Work, nothing you would not want your wife/husband, your girlfriend/boyfriend, your mother or your kid sister seeing on your screen.
6. Any personal attacks, any spam, any advertising, any trolling, or any abuse of the rules will result in your account being removed.
7. Not everyone's first language is English. Be understanding.
Please respect the community and respect each other. We are of many cultures so remember that. Don't assume others understand you are joking, don't belittle anyone for taking offense or being thin skinned.
We are a community for software developers. Leave the egos at the door.
cheers,
Chris Maunder
The Code Project | Co-founder
Microsoft C++ MVP
modified 16-Sep-19 9:31am.
|
|
|
|
|
Wordle 711 5/6
β¬π¨π¨β¬π©
β¬π¨β¬π©π©
π©β¬β¬π©π©
π©β¬π¨π©π©
π©π©π©π©π©
|
|
|
|
|
Wordle 711 4/6
π©β¬π©π¨β¬
π©β¬π©β¬π©
π©π¨π©β¬π©
π©π©π©π©π©
|
|
|
|
|
Wordle 711 4/6
β¬β¬β¬β¬π©
π¨β¬π¨π¨β¬
π¨β¬π¨π¨π©
π©π©π©π©π©
|
|
|
|
|
Wordle 711 4/6*
π©β¬β¬β¬π©
π©β¬β¬π©π©
π©β¬β¬π©π©
π©π©π©π©π©
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Wordle 711 2/6
π©β¬π©β¬π©
π©π©π©π©π©
A few possibilities, got lucky for a change.
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
- I just can stand it when someone doesn't use braces in IF statements:
static void Main(string[] args)
{
bool isTrue = false;
if (isTrue)
Console.WriteLine("line1") ;
Console.WriteLine("line2");
Console.WriteLine("line3");
Console.ReadLine();
} - XAML where the code is all on one line! (This is all on one line!)
<Button x:Name="cmd5" Style="{StaticResource MetroButton}" Content="Remove" RenderTransformOrigin="0.438,2.667" IsDefault="True" Click="cmdRemove_Click" DockPanel.Dock="Right" Margin="0" Width="66" VerticalAlignment="Center" Visibility="Collapsed"/> - First brace not on a new line:
static void Main(string[] args)
{
bool isTrue = false;
if (isTrue) {
Console.WriteLine("line1");
}
Console.WriteLine("line2");
Console.WriteLine("line3");
Console.ReadLine();
}
What bugs you when you see someone else's code?
In theory, theory and practice are the same. But in practice, they never are.β
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
|
|
|
|
|
|
Funny enough, for JavaScript it's the exact opposite for #3. My peeve would be not using 1TBS for JavaScript/Typescript. There's actually a technical reason why, but now it's just so ingrained. And it's easy to spot a JavaScript rookie vs a pro if they try and format it like C#.
Totally agree about the empty catch blocks though. Even in JS.
Jeremy Falcon
|
|
|
|
|
Agreed with the opening brace placement in JS/TS vs C#. I've done very little JS, but this is something I've quickly adopted, despite doing the opposite in C#. If I see an opening brace on a line on its own in JS, it just looks wrong to me.
Somehow I can manage do the context switch in C# as if it was second nature, which is just as well, otherwise I'd really get stuck on this sort of thing.
Coding standards are weird. It's just as well there's so many of them.............
|
|
|
|
|
dandy72 wrote: Somehow I can manage do the context switch in C# as if it was second nature That's a sign of a good coder actually. Like with JS, there's a technical reason. Being able to let go of things (if there's a good reason) is a good thing. Like for instance, I love camel case. But, I doubt that would fly in Rust.
dandy72 wrote: Coding standards are weird. It's just as well there's so many of them............. Preach.
Jeremy Falcon
|
|
|
|
|
Kevin Marois wrote: What bugs you when you see someone else's code?
1. "Hungarian" variable names
2. TAB instead of spaces
3. TAB instead of spaces
...
100. Did I mention "TAB instead of spaces"?
Mircea
|
|
|
|
|
Item 1 is just evil.
Item 2 - it's xaml. It's not code
Item 3 - I prefer braces to be on the line below, but it's just habit. damned if I know where I picked up on that. I just don't think the opening brace on the same line is clear. But that is my preference. I know other folks that go BSC if the brace is under the if...
Charlie Gilley
βThey who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.β BF, 1759
Has never been more appropriate.
|
|
|
|
|
charlieg wrote: Item 3 - I prefer braces to be on the line below, but it's just habit. damned if I know where I picked up on that. I just don't think the opening brace on the same line is clear. But that is my preference. I know other folks that go BSC if the brace is under the if... Except in JavaScript (I realize the OP is C#... just saying) there's a legit reason to not use a new line for the brace.
Jeremy Falcon
|
|
|
|
|
Clicked on the link, read what was said there and pondered for a minute.
I've decided that is one of the dumber language decisions I've ever seen.
Iβve given up trying to be calm. However, I am open to feeling slightly less agitated.
Iβm begging you for the benefit of everyone, donβt be STUPID.
|
|
|
|
|
MarkTJohnson wrote: I've decided that is one of the dumber language decisions I've ever seen. People that dismiss JavaScript really just don't know it. Yes, it started off quickly/rushed, but it's come a long way. It's different. It's both functional and OOP. Nothing more. Nothing less. I think it's a great language, minus a few little quirks... which most languages have.
It started off being web centric, so it has historic "issues" from that like ASI. Most web languages are script kiddie friendly, but JavaScript/ECMAScript has come a long, long way. I can promise you that most issues with the language is more so due to it being popular and 99% of people really knowing nothing about it.
Not to mention, it's fast. Really fast, thanks to the optimizations over the years. Of course, not Rust/C++/C# fast... but it's one of the fastest scripting languages out there.
Jeremy Falcon
|
|
|
|
|
Replying/preaching 6 times in one these types of threads - interesting.
Trying to defend javascript - priceless.
|
|
|
|
|
Slacker007 wrote: Trying to defend javascript - priceless. Always man.
Jeremy Falcon
|
|
|
|
|
1.2.3.YES
Give me coffee to change the things I can and wine for those I can not!
PartsBin an Electronics Part Organizer - An updated version available! JaxCoder.com
Latest Article: Simon Says, A Child's Game
|
|
|
|
|
Use of literal values annoys me a lot. Especially when that hard-coded value needs to be changed.
"They have a consciousness, they have a life, they have a soul! Damn you! Let the rabbits wear glasses! Save our brothers! Can I get an amen?"
|
|
|
|
|
That's a good one. Especially if that literal is used more than once...
Jeremy Falcon
|
|
|
|
|
Kevin Marois wrote: I just can stand it when someone doesn't use braces in IF statements: For me, that's acceptable... as long as the rest of the code is formatted well. Especially for stuff that's terse in nature like if (!blah) return; at the start of a routine. But it would have to be something short and simple.
Kevin Marois wrote: What bugs you when you see someone else's code? If we harken back to the first point... when folks don't use spacing properly. Code should read like text. And in English we have paragraphs. When I see large code files with no blank lines... I mean... what?
function checkout(goodsPrice, shipmentPrice, taxes) {
const total = goodsPrice + shipmentPrice + taxes;
const para = document.createElement("p");
para.textContent = `Total price is ${total}`;
document.body.appendChild(para);
}
function checkout(goodsPrice, shipmentPrice, taxes) {
const total = goodsPrice + shipmentPrice + taxes;
const para = document.createElement("p");
para.textContent = `Total price is ${total}`;
document.body.appendChild(para);
}
Jeremy Falcon
|
|
|
|
|
At least in C/C++ putting the opening bracket on the same line as a function definition
int f(int x) {
} But that's OK in classes - particularly if its a one-liner
class C {
int x;
int f(int n) { return x*n; }
{;
Keep Calm and Carry On
|
|
|
|
|
It's not exactly code, but comment boxes in the form of complete rectangles. The pinheads who originally drew them presumably believed that other people adding comments in the box would bother to keep its right-hand border nicely aligned. Not to mention that many of those comments provided a revision history for even the most trivial changes when, even in 1981, we had a source code management system that provided a full history, so that you could see who made each change, why, and get a diff between whichever versions you wanted.
|
|
|
|
|
I would take offense to #1 and #2, but not #3. I use the K&R style of bracing.
/ravi
|
|
|
|