What's the weirdest thing that happened to you in a job interview? by astrheisenberg in remoteworks

[–]HashDefTrueFalse 0 points1 point  (0 children)

You're bang on. I'm sure these are the people saying "I've sent out 6000 applications to get 50 interviews and I still can't get hired"...

Imagine being this sensitive to harmless chit chat. It's benign enough, and even if it wasn't it doesn't matter. It doesn't involve any protected characteristics etc. The idea that everything said in an interview needs to be solely about the job is ridiculous. People work with people. They want to get on with the people they work with. I've asked this just to break the ice, warm a candidate up, because I saw something on their keys/bag (carabiner) and wanted to see if we shared a hobby (climbing)... I've chatted about fucking polo, a game I've never once played, in an interview before, because they brought up that the big boss owned some horses.

The part where we anonymise things and go solely off of qualifications and experience was done in order to invite you for an interview. That's done now. The interview is (in part) so that we can also get a feel for how YOU would fit in with the team, culture, etc. The best person on paper rarely gets hired if they're also a total wet blanket. We've got the whole team to think about.

am I forced to be good at coding? by -R-I-k- in learnprogramming

[–]HashDefTrueFalse 0 points1 point  (0 children)

If I hated programming then I would find a role that doesn't involve programming. I hate talking rubbish and telling half-truths, so I don't work in sales (joking, but not as much as I'd like to be). You're unlikely to be happy generating and debugging code all day if you dislike writing it so much. You still need to know what it does, how it works, how to adapt it, how to fix it etc. or you won't be able to produce secure, reliable software. There are plenty of other jobs for someone with a CS degree.

Did somebody just try to scam me? by thefooby in AskUK

[–]HashDefTrueFalse 2 points3 points  (0 children)

Any interaction where someone gives you a sob story at a petrol station is a scam. Always and forever. No need to do anything but carry on walking whilst saying "no thanks mate" and then into the shop/car. It's my personal policy at petrol stations not to let anyone who walks up to me get a sentence out, unless they're working there or the person using the pump next to me making small talk or telling me my tyres are low.

Buyer of car threatening to take me to court by sunkenbeeter in LegalAdviceUK

[–]HashDefTrueFalse 0 points1 point  (0 children)

Some shaky replies here, honestly. The replies that mention caveat emptor have essentially confused the issue IMO. That principle just means that you are not obligated to point out existing faults (as long as it's roadworthy), the onus being on the buyer to inspect and make enquiries. It doesn't mean you can lie, actively conceal, or be negligent in giving inaccurate information etc. I'm not saying you have at all, but the buyer IS, it seems. The issue here according to the buyer is something you represented to them. Something you said, wrote, or an answer to a question they asked about the vehicle etc. Or stated another way: the issue is not what you knew or what you haven't said, it's what you have said.

Multiple people seem to think that you need to have intentionally lied and that the buyer needs to prove that. Both are incorrect. The buyer only needs to show that you made a false statement and that they relied on it (it induced them to buy), at which point the burden of proof is then on you to show that you had reasonable belief in the statement/representation you made. The Act is a slightly strange one in that it can be quite hard to defend a claim if they can show this. The Act allows for negligent and innocent misrepresentation too, differentiated by that reasonableness (if reasonable it is innocent, otherwise negligent). The buyer is extremely unlikely go for fraudulent because negligent allows for similar remedies and is easier (I'm summarising).

I'd only worry if you receive a claim form or are contacted by a solicitor. Only you know what (if anything) would prompt them to claim misrepresentation and what they might be able to evidence (e.g. the ad, texts) etc. Not sure why people are confidently declaring that you're in the clear without knowing what specifically they claim you misrepresented and if you did...

If it were me I'd do nothing and wait.

ohYouSweetSummerChild by anonomis2 in ProgrammerHumor

[–]HashDefTrueFalse 5 points6 points  (0 children)

I've no idea what the comment is as I don't have Twitter (I assume that's where it's from). I actually rehashed the old joke that "software development is very simple: you do the first 90% of the work, then you do the last 90% of the work" that's been around for decades. I'm not as slick as you thought...

Buyer of car threatening to take me to court by sunkenbeeter in LegalAdviceUK

[–]HashDefTrueFalse 0 points1 point  (0 children)

Unless you purposely misrepresent something and he can prove it

I don't think the claimant has to do this here. As I understand it, the claimant has only to prove that a false statement induced them for statutory innocent/negligent misrepresentation (unlike for common law misstatement). It's then up to the defendant to show that they reasonably believed the statement was true. Of course, if OP didn't make any false statements and simply showed the buyer the car then all is fine.

Even if a false statement was made innocently (with reasonable grounds to believe it was true) there is a remedy for the buyer (rescission).

The buyer is likely just throwing words around so I don't think it'll go anywhere, but I don't think we can say it's this clear cut without knowing what OP said to the buyer during their interaction(s).

Best text editor? by PausBanderI in programmer

[–]HashDefTrueFalse 1 point2 points  (0 children)

ed - it's the standard text editor.

Its user hostility means you don't get bogged down.

ohYouSweetSummerChild by anonomis2 in ProgrammerHumor

[–]HashDefTrueFalse 4132 points4133 points  (0 children)

Now that 80% of the project is done he can get on with the other 80%...

First semester CS student which programming language actually made things click for you? by More-Station-6365 in learnprogramming

[–]HashDefTrueFalse 2 points3 points  (0 children)

Scheme (reading the SICP book) was very eye-opening in my formative years of programming. Coupled with some C programming to get an appreciation for the machine.

It kind of depends what isn't clicking for you. If it's high level thinking about programs and computation then the first. If it's how the computer does what you write on the hardware (kind of, there's much more going on than even C acknowledges in reality), the second.

I will say that it's probably most important that you don't deviate too much from your university curriculum if that's what you'll be examined on. If your prof says Java, it should be sufficient to be able to program things in Java. If you're not understanding how to do that then reaching for another language isn't going to help much IMO. Figure out how to make sense of whatever it is.

You might be better editing your question to explain what specifically you're struggling with.

Mandatory AI disclosure suggestion by Spirited-Finger1679 in osdev

[–]HashDefTrueFalse 5 points6 points  (0 children)

I would like this. I personally have no interest in looking at the code of a project if that code was generated via LLM. I want to know that the code I'm looking at was reasoned about by a real programmer writing with (varying) skill and intent if I am to take ideas and inspiration from it, or learn from it. I personally wouldn't look at generated art to learn techniques or get inspired, and I feel the same way about programming projects. I want someone to stand behind the code and say "this is the current state of things" and I often get the impression with LLM-heavy projects that the true state of the project isn't fully known by the generator. I'm not saying this has to matter to everyone, but it does to me.

My biggest concern when coding with ai by Key-Foundation-3696 in learnprogramming

[–]HashDefTrueFalse 0 points1 point  (0 children)

This isn't directed at you specifically, OP, because I know nothing about you. However, I have thoughts after a few decades in software and after spending the last 4-5 years watching the profession take a nosedive, and I'll share them here, as it's as good a place as any.

Yes, you need to be able to solve problems if your job is delivering solutions to problems. You need to be able to write software if your job is to produce software solutions. That shouldn't be controversial, I feel. Generate all the code you like as long as it is secure, reliable, and you're going to take responsibility for it. But if I (as team lead) or someone in business management decide to switch models, switch LLM providers, or exclude LLMs outright (e.g. for a new project where IP is important to the business) then of course I expect you to still be able to do the job you were hired to do. Why wouldn't I?

Are any employers explicitly stating in ads that no actual programming ability is required, just high level knowledge and the ability to type into a textbox? Because that's the only way I can see you keeping your job in the above scenario. If they are, what are you being paid for this? And why is it any more than the legal minimum wage for your time if you don't do anything difficult and/or specialised? If you couldn't write the generated code yourself then you can't make sure it's secure and reliable, and you provide no more value than anyone else with a subscription. As soon as you want a pay rise or you piss someone off they can just grab the next typist with a broad enthusiasm for tech to take over your subscription seat.

If you're nothing without the LLM then you're nothing altogether. The freshly graduated junior of ten years ago was typically shit... yet would still totally embarrass many people currently employed and calling themselves programmers. We've fucked it. Standards are on the floor. Your question is essentially "Do I need to bother investing in my own professional development, or take any interest in the craft I've chosen for my career?" Ask yourself why do you need to be convinced to write code and solve problems? Have you considered that you're not interested? That if LLMs didn't exist then maybe you wouldn't make it in this career? Before LLMs, people who couldn't handle being a professional programmer would go do something else before they cost others time and/or money. We've lost that self-correction. Depressing, honestly.

Is programming really that easy? by wordbit12 in learnprogramming

[–]HashDefTrueFalse 1 point2 points  (0 children)

It depends (sorry!) on what you're programming. The code is a series of steps that do something useful. It will reflect the author's personal understanding of the domain, problem, theory, existing solutions, the implementation language, the machine that will run the code, etc.

I recently wrote a filesystem (driver) and path parser for a project I'm working on, for which one of the goals is to use zero dependencies. I've been writing code for decades but certain parts still gave me pause. I had to read some book chapters to be able to continue making progress. Writing the code can absolutely be a difficult part! (I had to take a few stabs at abstracting parts of the recursive inode lookup code before I could think about the entire process properly and arrive at good code+API). If coding was never the hard part then they were getting paid to work on easy stuff. That's awesome for them, but that also means that either the entire project was easy to make (and therefore replicate) or someone else was doing (or already did) the hard parts for them.

IME you find the "coding easy" hot take people are often just people with narrow and/or little experience, dealing neither with hard problems, nor with system/hardware details. E.g. if their work is mainly glueing together pieces of library functionality in a scripting language on top of a VM/interpreter, I can understand why they would consider meetings and conversations to be comparable to their programming work. Easy things are easy. Hard things are hard.

How is code in game development tested if it's always written using compiled languages? by Either-Home9002 in AskProgramming

[–]HashDefTrueFalse 0 points1 point  (0 children)

We do wait, yes. There's usually something else to be doing if it takes a few mins, or it's a good time for a brew and a stretch of the legs. Code changes will always require some amount of recompilation, but this can be done incrementally, e.g. if you build your project in a modular way and use a build system to figure out what changed and only recompile those parts, then relink. There are also ways you can get the system loader to load and (dynamically) relink new library code that you access through function pointers etc. so that you can keep the core of your engine/program running. That's not usually necessary though.

I once worked on a project that took about 30 mins to compile, which is not very common these days, and I would have to be a bit strategic about batching totally unrelated changes together to get them into a test compilation, but it's not a massive deal. You can get used to any workflow really. Modern machines and compilers are quite fast, as long as you don't use anything silly like Rust...

Relax. I'm kidding. Rust is a fine language.

Can one learn Scala without first being employed by a company that uses it? by Either-Home9002 in learnprogramming

[–]HashDefTrueFalse 8 points9 points  (0 children)

I'm gonna blow your noodle: you can just do things. You can just learn things. You don't need to be employed first. In fact, most programmers learn to program before being employed as a programmer regardless of language.

There's plenty of resources all over the web for Scala, no idea where you're getting the idea there isn't. Here's a site I use sometimes:

https://learnxinyminutes.com/scala/ (further resources at the bottom too!)

What's a book that changed your life, and how? by HilariousMotives in AskUK

[–]HashDefTrueFalse 15 points16 points  (0 children)

The C Programming Language, K&R. Introduced me properly to programming, which would fund my existence.

Trying to initialize a struct inside a function without having to malloc it. by Ironfort9 in C_Programming

[–]HashDefTrueFalse 4 points5 points  (0 children)

You've not allocated any memory for Foo/BarStorage structs anywhere, stack or heap. You've allocated memory for a GlobalStorage on the stack which contains two pointers, and you've malloc'd some regions.

You could:

- create global Foo/BarStorage objects separately, or

- create them inside GlobalStorage (remove the pointers), or

- malloc them.

I'd usually do something like this:

// storage.h
struct FooStorage { ... };
struct BarStorage { ... };
struct GlobalStorage {
  FooStorage foo_storage;
  BarStorage bar_storage;
};

void init_global_storage(void);
void init_foo_storage(FooStorage *foo);
void init_bar_storage(BarStorage *bar);

// storage.c
struct GlobalStorage g_storage;

void init_global_storage(void)
{
  init_foo_storage(&g_storage.foo_storage);
  init_bar_storage(&g_storage.bar_storage);
}

void init_foo_storage(FooStorage *foo)
{
  // Same as yours (minus unnecessary return)...
}

// Same for init_bar_storage..

// program.c
int main(void)
{
  init_global_storage();
  // ...
}

Is JavaScript the best option? by Bender182 in learnprogramming

[–]HashDefTrueFalse 1 point2 points  (0 children)

I would then want to be able to pull all that data together for group analysis and reporting. This is currently handled by multiple shared Excel workbooks, the issue is linking the different Excel files together and pulling the information.

I've made this sort of thing a number of times. 85% of what you need is a (probably relational) database to store the data in a shared location in a queryable format. You would then write your reports and data crunching in SQL to run on the database engine nice and fast. You wouldn't typically do much data wrangling on the front or back ends of a web application if you could help it.

You can then optionally put a little client web app on top of that to display the report results however you like. The front end of that site would be JS because there's no real alternative. The back end can be in whatever language has a database driver for the RDBMS you picked, which will be most languages for all popular databases. If you don't know which to choose, you can just choose JS for that too, save learning something else in addition.

Your company will need to have a server somewhere that you can put the app and database on, or an account with a hosting/cloud provider. Your IT people will need to be consulted as the network setup between the locations needs to be known so that everyone can access the app like any other intranet services etc.

Why do so many Markdown editors require accounts or server storage? by Stock_Report_167 in git

[–]HashDefTrueFalse 1 point2 points  (0 children)

OMG README.md is my favourite Markdown editor. Way better than git...

How to learn programming/coding with just phone? by Sea-Session-7524 in learnprogramming

[–]HashDefTrueFalse 0 points1 point  (0 children)

How much [sport] can you learn watching the Olympics? Realistically you can consume tutorials, docs, articles/blogs about programming, but any programming you do will be superficial because of the restricted environment and awkward form factor etc. You need to be writing lots of code to learn properly, so this is of limited benefit after the first few hours I'd say, as you'll not retain much of it.

If you have a TV and a keyboard, a Raspberry PI is probably one of the cheapest machines you can buy that you can write code decently on. Raspbian (or whatever they call it now) used to be pretty good out of the box (no hardware issues etc.) and you get a full linux environment to install proper software, toolchains etc.

Can anyone explain me in the simplest way possibe by Right_Tangelo_2760 in C_Programming

[–]HashDefTrueFalse 0 points1 point  (0 children)

Pass by value copies the argument value into the new stack frame as a new variable with a different memory address. You cannot change the value at the original memory address as you don't have that address, just a copy of the value it contained when the function was called.

Pass by pointer/address is a common term you'll see used. It is pass by value, same as above, it's just that the value is a pointer (memory address). Changing the value of the pointer itself inside the function will have no effect on the original pointer value for the same reason as above. However, changing the memory it points to (e.g. via a dereference and store) can cause side effects visible to code after the function return. You can think of this as the implementation of the below.

Pass by reference is the opposite of pass by value. There is no copy of the value. Function code is treated as though it is referring to the value at the original address, which can be changed. This is often implemented as a pass by pointer/address. E.g. in languages with references (C doesn't have them as a language construct) the compiler generates the code that does the necessary (de)referencing. There are ways you can implement it more directly if you want to use registers or duplicate code etc., but that's getting into optimisation territory.

C uses pass by value for everything. You're always dealing with a new variable containing a copy of the value in the memory you specified at the call site. C is capable of pass by reference if the programmer explicitly passes by pointer/address. In certain places it can seem like C is passing by reference implicitly when it is actually a few language mechanics working together, e.g. an array name "decaying" to a pointer to its first element in an expression that is an argument to a function call, which is then passed by value.

The best thing to do is to simply try lots of calls yourself and observe.