| ChatGPT is already chipping away at my Google searches. I'm more and more just starting there for coding related questions. I've had chatgpt help me with the following just this week among other things. - solved a complex issue with scaling and transformations using pixijs upon providing a code example. The solution was 99% there and saved me hours of debugging. - refactored JavaScript to the async/await pattern - simplified a complex nested logic in c# with citations - scaffolded a MySQL create table statement upon providing several c# classes. Again saved me the tedious steps of typing them out. |
It supplied this :
First problem, it's version, length, flags. Second problem, length is 24 bits, not 16. Third, 24 bits unsigned won't fit in a Java int (which is signed). Then there is the extra masking, which isn't a bug but is (I'm reasonably sure) unnecessary.That's 3 sneaky bugs in 4 lines of code, and it didn't even try to parse the rest of the header.
I'm impressed that it produces _anything_, but it's dangerous to trust.
ChatGPT is as reliable a source as any friend in a pub after 3 beers. It is definite in its answer, convincing with its phrasing and more than likely misremembering something it overheard on the radio while driving to work.
When I tried re-prompting, it produced more complicated, just as incorrect code.