|
This code sucks.
Why aren't you using dependency injection?
I had expected some sort of repository pattern.
Your code that returns "Hello World" should implement an IHelloWorld interface.
You probably want to make a base class as well so implementers have something to go with out of the box.
I don't see any unit tests, so how do you know this works?
Also, where is the documentation? No programmer is ever going to understand what you wrote. Because you do everyone should, right?
And do you have a build server?
We want to make sure our code is validated as soon as it's put into source control.
You need it all, unit tests, database tests, UI tests, API tests, pen tests, integration tests, static code analyzers and, of course, automatic deployment.
Please read a book before you post some quick and dirty code in here
|
|
|
|
|
... such stuff as dreams are made on
|
|
|
|
|
"There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare
Home | LinkedIn | Google+ | Twitter
|
|
|
|
|
You forgot AI. The code needs AI. At least 3 tablespoons of AI.
/ravi
|
|
|
|
|
And also this NuGet stuff is missing
modified 19-Jan-21 21:04pm.
|
|
|
|
|
Yep, woefully under-engineered!
We should have an inverse "code golf" tournament where the winner is the person who produces the longest version of "Hello World."
Slogans aren't solutions.
|
|
|
|
|
They already did something quite similar here[^].
if (Object.DividedByZero == true) { Universe.Implode(); }
Meus ratio ex fortis machina. Simplicitatis de formae ac munus. -Foothill, 2016
|
|
|
|
|
Ah, so they did, along with this one which is an even closer challenge.
I often wonder what the code golf community could achieve if they ever applied themselves to something useful!
Slogans aren't solutions.
|
|
|
|
|
Sander Rossel wrote: Please read a book
I don't think such a book exists. You should write it!
Marc
|
|
|
|
|
The books in my signature will take care of the OOP and database issues.
As for the CI aspect, I'm currently working on it!
|
|
|
|
|
I think he meant this one[^].
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
You sir are right. I should walk back to my cubical and start refactoring at once.
By the way I read your SQL book. One thing I am really thankful for is new shortcut I learned Ctrl+Shift+R to refresh SSMS cache.
Zen and the art of software maintenance : rm -rf *
Maths is like love : a simple idea but it can get complicated.
|
|
|
|
|
virang_21 wrote: I read your SQL book Awesome, thanks!
virang_21 wrote: shortcut I learned Ctrl+Shift+R to refresh SSMS cache If that's the only thing you've learned from my book I'll call that a win!
|
|
|
|
|
I think it's examples like this that Joel Spolsky had in mind when he coined the phrase "Astronaut Architects"
"There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare
Home | LinkedIn | Google+ | Twitter
|
|
|
|
|
The major fault here is that it should include multilingual support: Globalization is important, you know!
And where are the unit tests?
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
Interplanetary support should be included, too. What happens if the code is run on Mars?
If you have an important point to make, don't try to be subtle or clever. Use a pile driver. Hit the point once. Then come back and hit it again. Then hit it a third time - a tremendous whack.
--Winston Churchill
|
|
|
|
|
The real problem will be translating it to Vogon Poetry.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
Vogan Poetry
Oh freddled gruntbuggly,
Thy micturations are to me,
As plurdled gabbleblotchits,
On a lurgid bee,
That mordiously hath blurted out,
Its earted jurtles,
Into a rancid festering confectious organ squealer. [drowned out by moaning and screaming]
Now the jurpling slayjid agrocrustles,
Are slurping hagrilly up the axlegrurts,
And living glupules frart and slipulate,
Like jowling meated liverslime,
Groop, I implore thee, my foonting turling dromes,
And hooptiously drangle me,
With crinkly bindlewurdles,
Or else I shall rend thee in the gobberwarts with my blurglecruncheon,
See if I don't!
Zen and the art of software maintenance : rm -rf *
Maths is like love : a simple idea but it can get complicated.
|
|
|
|
|
Could be worse.
Could be Paula Nancy MiIllstone Jennings.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
That's easy:
int main(void)
{
printf("Goodbye, World.\n")'
return 0;
}
If you have an important point to make, don't try to be subtle or clever. Use a pile driver. Hit the point once. Then come back and hit it again. Then hit it a third time - a tremendous whack.
--Winston Churchill
|
|
|
|
|
I can't believe nobody's pointed out the compiler error in your code!
CS1520 Method must have a return type
And since you're calling the method from outside of the class, you'll also need an access modifier. (The default is private .)
namespace something.BL
{
public class SomeClass
{
public string SayHello()
{
...
}
}
}
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Years before the first "Hello World", in the mid-1970s, a language was developed at the Norwegian Technical University, called "Mary" (named after the girlfriend of the chief designer). The very first sample program in the introductory book printed out:
Mary has been executed
The chief developer broke up with his girlfriend, but I don't know if that happened befor the program was written. Maybe the breakup was a result of the program. Or the other way around.
|
|
|
|
|
The Emoji Movie - Wikipedia[^]
What. The. F***.
Originally found here[^]
What do you get when you cross a joke with a rhetorical question?
The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism.
Do questions with multiple question marks annoy you???
|
|
|
|
|
There was even a bidding war for the rights.
I wonder if it went above five bucks.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
That movie is a valid enough motivation to start a war.
CALL APOGEE, SAY AARDWOLF
GCS d--- s-/++ a- C++++ U+++ P- L- E-- W++ N++ o+ K- w+++ O? M-- V? PS+ PE- Y+ PGP t++ 5? X R++ tv-- b+ DI+++ D++ G e++>+++ h--- ++>+++ y+++* Weapons extension: ma- k++ F+2 X
If you think 'goto' is evil, try writing an Assembly program without JMP. -- TNCaver
"Go ahead, make my day"
|
|
|
|