ChatGPT Does JS Heavy Lifting
ChatGPT does the heavy lifting in coding!

ChatGPT Does JS Heavy Lifting

I have been using ChatGPT alot lately. And with coding it seems to work extremely well!

One time that was particuarly rewarding for me was a few weeks ago when I noticed that my son prefered to learn on the computer and he needed to practice his algebra problems.

I had been training myself on react.js on w3schools so I decided that I would create website that used react.js to display 10 2-step Algebra problems in 2 neat columns with a textbox by each problem. and a button at the bottom to click and get the number of correct answers.

I constructed my prompt carefully and I ran into an issue that ChatGPT seemed to cheat. I was asking it to give me whole random numbers for a,b,c,d, and d so that the problem would not be too difficult. In other words. In the expression ax(bx+c)/d=e, I wanted e to be a whole number as well as the other variables.

So what chatGPT would do is cut off the decimal for e in the Algebra problem which was not exactly correct.

What I had to do was start from e and go backwards until all of the random whole numbers were acquired for each variable using the reverse mathematical operation using javascript.

With a few more ChatGPT prompts, copy and pastes, and npm starts, I was able to get it working in one night. Success!

A few days later, I wanted to make the appearance of the problems look more like an actual algebra expresion, so again I asked the AI model to tell me what framework, I could use. It came up with mathjax.

I had a few issues in constructing the LaTeX string in sending it to the mathjax function but I was able to fix that. I was very happy that with ChatGPT I was able to use a framework that I hadn't used before and get it to work! It worked well and the expression displayed properly!

Since this time I've read articles on how to better engineer the prompt to the LLM ChatGPT. The most recent article that I read explains 12 tips. I had been using most of the tips. I'm learning every day and I hope you are too.



要查看或添加评论,请登录

社区洞察

其他会员也浏览了