10 Ways to Use ChatGPT as a Programmer

Brenda Peters
4 min readMay 1, 2023

--

When ChatGPT was launched, everyone feared our jobs were at risk. but machines are only sometimes efficient and the human element will always be needed.
Instead of despising ChatGPT, let us learn how to use it to our advantage to become better programmers.

Ways to use ChatGPT as a developer

You have to learn prompting, which is the way to talk to an AI efficiently.
The way you communicate with the ChatGPT determines how precise the answer it gives to you.
I will recommend you chat with the AI as you would with a human.

Also, the AI remembers the previous conversations and you can ask for more explanation on a given point that you don’t understand using your conversation with the AI.

Create a free account at chat.openai.com to begin, the free account is limited and has down times if you will be using ChatGPT for so many reasons, it is advised you get the paid version, as it is faster and more intelligent than the free version.

  1. General Learning Tool
    Just as we search on Google and other search engines, you can ask ChatGPT questions on any topic of your choice and it will give you steps on how to go about it.
Conversations with ChatGPT on general learning

2. Code Feedback and Refactoring
ChatGPT can help you review your code. Make suggestions on how to make it better.
In the code block, I used in my prompt, ChatGPT did not only review my code but test for negative cases and gave me a better solution.

3. Generating Sample / Dummy Data
This is one of my favorite use of ChatGPT because sometimes generating dummy data on your own can be a lot of work. But with the help of ChatGPT, you can generate dummy data in your preferred format.

dummy data generated using chatGPT

4. Find a Solution to a Specific Problem
You can ask ChatGPT for the steps or code to fix a particular issue. Getting code blocks like this can help reduce the amount of time spent looking for solutions on stack overflow, youtube, and Google. This can help with productivity.

Generate random number with ChatGPT in JavaScript

5. Switch between Programming Language
ChatGPT makes your job faster and does not put you out of your job. You can convert your code to another programming language. You can fix bugs in an application you are not too familiar with. But you have to know the basics of that language to do so.

6. Brainstorming
I use ChatGPT a lot for brainstorming, it can help you develop a vague idea. It can suggest projects for you to work on or use cases of a particular technology.

7. Write Documentation for your Code
You can give ChatGPT, a GitHub URL, it will generate documentation for you. You can also use ChatGPT to write ReadMe files.
Note: Sometimes, when the AI is generating a response, it stops. Just tell it to continue to finish the answer.

8. Create Basic UI Templates or Layouts
With ChatGPT you can generate the code for a basic website design. It may not be that stylish. But it can be a foundation for you to build upon.

Website layout written by ChatGPT

9. Get Details about an Error Message
If you encounter an error in your code, you can post the error message. ChatGPT can tell you about the error and help you rewrite the code to fix the error.

10. Write Unit Tests
You can use ChatGPT to generate unit tests for your application using any testing library of your choice.

Other uses of ChatGPT include:
* Summarize articles
* Explain Codebase
* Find Bugs
* Generate Tweets
* Write Blog Posts
* Tell you jokes

Feel free to explore ChatGPT as much as you can. There are a lot of things the AI can do. It helps you become a better developer overall.

Remember: ChatGPT won’t take your job, but the person using ChatGPT would.
Learn to use it to be on top of your game.

Thanks for reading

--

--

Brenda Peters

I am a full stack web developer. Welcome, here I post contents about web development and software engineering. Follow me, let walk the path together.