WebMay 25, 2024 · So is there a way to convert the country code to country name from javascript itself or I need to make one more API call to other url which will convert me … WebFeb 19, 2024 · JavaScript Esha98 / HackerRank-Javascript Sponsor Star 0 Code Issues Pull requests Discussions JavaScript's Optimal solutions for HackerRank javascript solutions hackerrank challenges javascript-es6 hackerrank-solutions hackerrank-challenges 10daysofjavascript hackerrank-javascript-solutions Updated on Feb 5 …
How to get country name from country code in javascript
WebMay 4, 2024 · async function findCountry (country) { for (let page = 1; page obj.name == country); if (obj) return obj; } } let country = "Belgium"; findCountry (country).then (obj => { if (obj) { console.log ("The capital of " + country + " is " + obj.capital); } else { console.log ("Could not find " + country); } }); … WebAug 28, 2024 · Hackerrank currently uses node version 14.x.xx which comes with axios . All you have to do is scroll to the top and import or require axios, then you can make use of axios.get () or axios.post () as the case may be. Share Improve this answer Follow answered May 22, 2024 at 14:44 Aniediabasi Etukudo 31 1 Add a comment 1 hydrock acoustics
HackerRank - JavaScript Basic Assessment - Country …
WebDec 7, 2024 · This code will send only the data for China into your initialize function. The trick is this part: data.filter (item => item.name === 'China') I assume you can rewrite the initialize function to process the data correctly. WebHacker Rank exercise- Get countries with population greater than p using http get Raw countries.js // TODO: Add pagination function getCountries(str, p) { let accum = 0; … WebSelected Solutions to HackerRank Javascript coding challenges - GitHub - eduzol/HackerRankJavascript: Selected Solutions to HackerRank Javascript coding … hydro city microgreens