If you are a learner or a professional programmer, then the new Bard coding features are a gift for you. The latest Bard update came with an ability to write computer code and perform coding tasks in twentyfold languages.
The capabilities include: writing code, suggesting improvements, debugging errors and explaining the code, line by line.
The list of programming languages include all major lingos: C++, Java, Javascript, Go, Python and Typescript.Â
Users can also use Bard to translate code from one language to the other. It can also help programmers optimize their code and suggest improvements to function faster.
Coding ability has been in the demand list of users who found Bard’s lacking ability in the field. Google set its priority to respond to these requests and added powerful programming features.Â
This is an impactful step towards learning and development of those who want to start and progress in the software development career. Programmers can use Bard to shorten their time on writing repetitive lines of code. and especially felt a need for a collaborative hand when shifting to a different programming language.
In addition to these impressive features, Bard can also write documentation and tutorials for the source code. This is good news especially for technical writers who now have a helping hand that can quickly help them understand and write specifications for software products.
Besides Google’s Bard, users also have other free-AI coding tools such as Github’s Copilot and Replit’s Ghostwriter; all of which show the potential to boost programmer productivity.
What it means for QAs?
Quality assurance leaders and beginners can use Bard in a number of ways. They can quickly create test cases, convert a test case into an automated script and identify defects that have the most risk.
Testing Bard and ChatGPT, head-on-head
How effective is Bard in coding?Â
To check this, an author of ZDNet tested Bard’s new coding capability against ChatGPT’s. And ChatGPT won.
Here’s a summary of Bard weaknesses compared to ChatGPT:
- Bard provided improper UI formatting when asked to write PHP code for a webpage.
- Bard took the wrong approach when asked to debug a code. When asked to ‘rewrite’ a code to something that also accepts decimal values as input, Bard created a different code from scratch. Instead of analyzing the code for input values and replacing the function, it came up with a completely new code and that too without helping the user with an explanation. Â
- Bard incorrectly identified an error in the code which was about a function with incorrect parameter pass. It stated that function takes one parameter instead of two, however it was not the case.Â
Conclusion
Bard can help you code in twenty programming languages, but it’s still in experimenting stage.Â
Google’s Paige Bailey, the product manager of Bard suggested in her blog post to ‘Always double-check Bard’s responses and carefully test and review code for errors, bugs and vulnerabilities before relying on it.’Â
This is because Bard is still in the experimental phase and it is vulnerable to mistakes. The AI is yet to be improved based on user feedback.
One good thing about making sure of avoiding buggy code is that Bard cites sources from where it fetched the code and code explanations, wherever possible.