u/david_fire_vollie

▲ 0 r/csharp

Is AI not well trained on CIL/assembly code?

Is AI not as well trained with low level languages due to the relatively low amount of information online compared to high level languages?

You have StackOverflow and many other websites with tutorials and QnAs to do with high level languages, but not many for CIL.

I prompted ChatGPT with this:

>Write a C# method called MethodA that calls MethodB.
MethodB does a mathemtical task that will result in an overflow.
MethodA should make sure MethodB is "checked" so that it throws an exception if an overflow happens.

And it provided me this solution which doesn't work:

public class Calculator
{
    public void MethodA()
    {
        checked
        {
            MethodB();
        }
    }

    public int MethodB()
    {
        int a = int.MaxValue;
        int b = 10;

        // This will overflow and throw OverflowException because of MethodA's checked context
        return a + b;
    }
}

You need to understand the CIL to understand why this doesn't work (hint: it's because it changes the add instructiont o an add.ovf instruction only for code directly inside the checked block).

I'm wondering if this lack of training could cause issues further down the track as AI develops and more developers focus even less on understanding how code works behind the scenes.

reddit.com
u/david_fire_vollie — 23 hours ago

Is it ok to switch off electricity to my hot water tank for 5 weeks?

We are going away for 5 weeks during winter, and to save money, I thought we could switch off the electricity to the hot water tank.
Are there any issues with doing this?

reddit.com
u/david_fire_vollie — 2 days ago

I passed Solutions Architect Associate - SAA-C03!

https://preview.redd.it/bqmv7bjvnh1h1.png?width=755&format=png&auto=webp&s=5c0de3f2358f5ce33a43b6d92575416edb1d052e

I had very little experience with AWS but wanted this to help me get my next job.
I started off getting AI to help me build a simple API in .NET from scratch concentrating on understanding how to set up the ALB, target groups, subnets, NAT gateway etc.
That really helped me understand the VPC resources.

For the rest of the concepts, I spent 4 months going through practice tests.
I never did the same practice test twice, and slowly my results started going from around 50% to a consistent ~80%.

I didn't do any videos, because I can't retain the info that way.
I found the practice tests were the best way to learn.
You don't risk accidentally memorising the answers if you don't do the same test twice.
I made sure I understood why the wrong answers were wrong, and read the explanation and any linked articles.

I plan to do Developer Associate next.

reddit.com
u/david_fire_vollie — 7 days ago

How do you pronounce sewerage?

I'm in Sydney and say it like Sue -ridge.

But I noticed Zoe Foster Blake says it like Sue-widge.

I'm just wondering if people say it differently depending on the city they're from.

reddit.com
u/david_fire_vollie — 7 days ago

I need to rent a car in Frankfurt and I'm a bit worried because of the reviews.
It seems almost all the rental companies have lots of bad reviews.

Is this normal in Germany, or is it just bad luck that Frankfurt hasn't got the best car rental companies?

Has anyone rented a car in Frankfurt? Which company would you recommend?

reddit.com
u/david_fire_vollie — 15 days ago

Is it normal to use Du if you're communicating over the internet, regardless of who your'e talking to?
I sent an email enquiry in German to a childseat company and I used "Sie".
However, in the reply, the person referred to me as "Du".

Since we are both adults who don't know each other, would we still need to use "Sie" when I meet him/her in person at the shop?
Or, because he/she has started replying with "Du" (and I will now do the same), does this mean we should use "Du" in person?

reddit.com
u/david_fire_vollie — 21 days ago