{"id":12482,"date":"2020-02-24T10:35:45","date_gmt":"2020-02-24T18:35:45","guid":{"rendered":"https:\/\/careerkarma.com\/blog\/?p=12482"},"modified":"2023-12-01T02:30:12","modified_gmt":"2023-12-01T10:30:12","slug":"ruby-while-loop","status":"publish","type":"post","link":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/","title":{"rendered":"Ruby While Loop"},"content":{"rendered":"\n<p>Loops are used in a number of programming languages to perform a similar task multiple times. For example, if we wanted to print out the name of every employee in a list, we may want to use a loop. Or if we wanted to capitalize every string in a list, we may also want to use a loop.<\/p>\n\n\n\n<p>In this tutorial, we are going to break down the basics of Ruby <code>while<\/code> loops. These types of loops can be used to execute specific code until a certain condition is met.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Loop Refresher<\/h2>\n\n\n\n<p>The most basic way to create a loop in Ruby is to use the <code>loop<\/code> method. The loop method takes a block of code, which is defined within curly braces, and will execute any code within that block. The loop will keep going until you press <code>Ctrl + C<\/code> <code>(Cmd + C on Mac)<\/code> to execute a break, or insert a <code>break<\/code> statement in the code.<\/p>\n\n\n\n<p>Here\u2019s an example of a loop in Ruby:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>loop do\n\tputs \"Hello world!\"\nend<\/pre><\/div>\n\n\n\n<p>When we run our code, <code>Hello world!<\/code> will be printed until we interrupt the program: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>Hello world!\nHello world!\nHello world!\nInterrupt: \u2026<\/pre><\/div>\n\n\n\n<p>Indeed, we have created an infinite loop. Each time our loop executes, our program goes through a <code>loop iteration<\/code>, and it will not stop until we execute an interrupt. We can use a <code>break<\/code> statement to stop our loop when an action is executed. Here\u2019s an example of a loop with a break statement:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>i = 0\nloop do\n\ti += 1\n\tbreak\nend\nputs i<\/pre><\/div>\n\n\n\n<p>Our program returns: <code>1<\/code>. In this case, our program stops running after the loop has executed once because there is a break statement in place. If we wanted our program to run five times, we could enclose our break in an <code>if<\/code> statement like this: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>i = 0\nloop do\n\ti += 1\n\tif i =&lt; 5:\n\t\tbreak\n\tend\nend\nputs i<\/pre><\/div>\n\n\n\n<p>Our program returns the following: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>1\n2\n3\n4\n5<\/pre><\/div>\n\n\n\n<p>As you can see, our program stops as soon as it has been executed five times. But there is a more efficient way to write this loop. By using a <code>while<\/code> loop, we can make our code cleaner and simpler.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Ruby While Loop<\/h2>\n\n\n\n<p>A while loop is a loop statement that will be run when a boolean expression is true. For example, a while loop may be run until a counter reaches 10, or until another condition is met. The while loop will stop as soon as the boolean expression is equal to false.<\/p>\n\n\n\n<p>Here is an example of a while loop that will count up to five and print the count as it goes: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>i = 0\nwhile i &lt; 5\n\tputs i\n\ti += 1\nEnd\nputs \"The counter is complete.\"<\/pre><\/div>\n\n\n\n<p>Our code returns the following: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>0\n1\n2\n3\n4\n5\nThe counter is complete.<\/pre><\/div>\n\n\n\n<p>Let\u2019s break down our code. On the first line, we define a counter variable, <code>i<\/code>. Then, on the next line, we create a while loop that will run until our counter is equal to five. As soon as our counter reaches <code>5<\/code>, the boolean expression will become <code>false<\/code>, and our program will stop.<\/p>\n\n\n\n<p>Then, on the next line, our program adds one to our counter, and then the program prints out our counter.<\/p>\n\n\n\n<p>Finally, as soon as the loop has been executed five times, the loop stops because <code>i<\/code> becomes equal to <code>five<\/code>, and so our conditional is false. But before <code>i<\/code> is equal to five, our conditional statement is true which means our loop runs. Thus, after <code>i<\/code> reaches five our final statement, <code>The counter is complete.<\/code> is printed.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Do While Loop<\/h2>\n\n\n\n<p>Do\/while loops work in a similar way to while loops, but with one key difference. The code in a do\/while loop is executed one time before a conditional check is run. Here\u2019s an example of a do\/while loop that will be executed until a user enters <code>BREAK<\/code>:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>loop do\n\tputs \"Enter BREAK to stop the program. Enter anything else to keep going.\"\n\tresponse = gets.chomp\n\tif response == \"BREAK\"\n\t\tbreak\n\tend\nend<\/pre><\/div>\n\n\n\n<p>Here\u2019s the output of our code: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>Enter BREAK to stop the program. Enter anything else to keep going.\nNOBREAK\nEnter BREAK to stop the program. Enter anything else to keep going.\nNOBREAK\nEnter BREAK to stop the program. Enter anything else to keep going.\nBREAK<\/pre><\/div>\n\n\n\n<p>As soon as we typed in <code>BREAK<\/code>, our program stopped.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Until Loop<\/h2>\n\n\n\n<p>Until loops, the opposite of the while loop, are not as common in practice but can be useful in some situations. Here\u2019s an example of an until loop:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>i = 0\nuntil i &gt; 5\n\tputs i\n\ti = i+1\nEnd\n  \nputs \"The program has been run.\"  <\/pre><\/div>\n\n\n\n<p>Our code returns the following: <\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>0\n1\n2\n3\n4\n5\nThe program has been run.<\/pre><\/div>\n\n\n\n<p>As you can see, our program runs until <code>i<\/code> is greater than <code>5<\/code>, after which point the program breaks and moves onto the next line of code.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p>While loops allow you to perform an action while a certain expression is equal to true. In this tutorial, we have discussed the basics of loops in Ruby. In addition, we outlined how to use a while loop, a do\/while loop, and an until loop, and discussed where they may be useful. Now you\u2019re ready to start using loops like a Ruby expert!<\/p>\n","protected":false},"excerpt":{"rendered":"Loops are used in a number of programming languages to perform a similar task multiple times. For example, if we wanted to print out the name of every employee in a list, we may want to use a loop. Or if we wanted to capitalize every string in a list, we may also want to&hellip;","protected":false},"author":240,"featured_media":12483,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[17278],"tags":[],"class_list":{"0":"post-12482","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-ruby"},"acf":{"post_sub_title":"","sprint_id":"","query_class":"Ruby","school_sft":"","parent_sft":"","school_privacy_policy":"","has_review":"","is_sponser_post":"","is_guest_post":""},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.0 (Yoast SEO v27.0) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Ruby While Loop: A Complete Guide | Career Karma<\/title>\n<meta name=\"description\" content=\"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Ruby While Loop\" \/>\n<meta property=\"og:description\" content=\"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\" \/>\n<meta property=\"og:site_name\" content=\"Career Karma\" \/>\n<meta property=\"article:publisher\" content=\"http:\/\/facebook.com\/careerkarmaapp\" \/>\n<meta property=\"article:published_time\" content=\"2020-02-24T18:35:45+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-12-01T10:30:12+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1000\" \/>\n\t<meta property=\"og:image:height\" content=\"668\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"James Gallagher\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@career_karma\" \/>\n<meta name=\"twitter:site\" content=\"@career_karma\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"James Gallagher\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\"},\"author\":{\"name\":\"James Gallagher\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94\"},\"headline\":\"Ruby While Loop\",\"datePublished\":\"2020-02-24T18:35:45+00:00\",\"dateModified\":\"2023-12-01T10:30:12+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\"},\"wordCount\":706,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg\",\"articleSection\":[\"Ruby\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\",\"url\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\",\"name\":\"Ruby While Loop: A Complete Guide | Career Karma\",\"isPartOf\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg\",\"datePublished\":\"2020-02-24T18:35:45+00:00\",\"dateModified\":\"2023-12-01T10:30:12+00:00\",\"author\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94\"},\"description\":\"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.\",\"breadcrumb\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage\",\"url\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg\",\"contentUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg\",\"width\":1000,\"height\":668},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Blog\",\"item\":\"https:\/\/careerkarma.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Ruby\",\"item\":\"https:\/\/careerkarma.com\/blog\/ruby\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Ruby While Loop\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#website\",\"url\":\"https:\/\/careerkarma.com\/blog\/\",\"name\":\"Career Karma\",\"description\":\"Latest Coding Bootcamp News &amp; Career Hacks from Industry Insiders\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/careerkarma.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94\",\"name\":\"James Gallagher\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/01\/james-gallagher-150x150.jpg\",\"contentUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/01\/james-gallagher-150x150.jpg\",\"caption\":\"James Gallagher\"},\"description\":\"James Gallagher is a self-taught programmer and the technical content manager at Career Karma. He has experience in range of programming languages and extensive expertise in Python, HTML, CSS, and JavaScript. James has written hundreds of programming tutorials, and he frequently contributes to publications like Codecademy, Treehouse, Repl.it, Afrotech, and others.\",\"url\":\"https:\/\/careerkarma.com\/blog\/author\/jamesgallagher\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Ruby While Loop: A Complete Guide | Career Karma","description":"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/","og_locale":"en_US","og_type":"article","og_title":"Ruby While Loop","og_description":"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.","og_url":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/","og_site_name":"Career Karma","article_publisher":"http:\/\/facebook.com\/careerkarmaapp","article_published_time":"2020-02-24T18:35:45+00:00","article_modified_time":"2023-12-01T10:30:12+00:00","og_image":[{"width":1000,"height":668,"url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg","type":"image\/jpeg"}],"author":"James Gallagher","twitter_card":"summary_large_image","twitter_creator":"@career_karma","twitter_site":"@career_karma","twitter_misc":{"Written by":"James Gallagher","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#article","isPartOf":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/"},"author":{"name":"James Gallagher","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94"},"headline":"Ruby While Loop","datePublished":"2020-02-24T18:35:45+00:00","dateModified":"2023-12-01T10:30:12+00:00","mainEntityOfPage":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/"},"wordCount":706,"commentCount":0,"image":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage"},"thumbnailUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg","articleSection":["Ruby"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/","url":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/","name":"Ruby While Loop: A Complete Guide | Career Karma","isPartOf":{"@id":"https:\/\/careerkarma.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage"},"image":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage"},"thumbnailUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg","datePublished":"2020-02-24T18:35:45+00:00","dateModified":"2023-12-01T10:30:12+00:00","author":{"@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94"},"description":"\u2018While\u2019 loops allow programmers to perform an operation until a certain criteria is met. Learn about how to use while, do\/while, and until loops in Ruby.","breadcrumb":{"@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/careerkarma.com\/blog\/ruby-while-loop\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#primaryimage","url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg","contentUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/RUBY-WHILE-LOOP.jpg","width":1000,"height":668},{"@type":"BreadcrumbList","@id":"https:\/\/careerkarma.com\/blog\/ruby-while-loop\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog","item":"https:\/\/careerkarma.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Ruby","item":"https:\/\/careerkarma.com\/blog\/ruby\/"},{"@type":"ListItem","position":3,"name":"Ruby While Loop"}]},{"@type":"WebSite","@id":"https:\/\/careerkarma.com\/blog\/#website","url":"https:\/\/careerkarma.com\/blog\/","name":"Career Karma","description":"Latest Coding Bootcamp News &amp; Career Hacks from Industry Insiders","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/careerkarma.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/e79364792443fbff794a144c67ec8e94","name":"James Gallagher","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/01\/james-gallagher-150x150.jpg","contentUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/01\/james-gallagher-150x150.jpg","caption":"James Gallagher"},"description":"James Gallagher is a self-taught programmer and the technical content manager at Career Karma. He has experience in range of programming languages and extensive expertise in Python, HTML, CSS, and JavaScript. James has written hundreds of programming tutorials, and he frequently contributes to publications like Codecademy, Treehouse, Repl.it, Afrotech, and others.","url":"https:\/\/careerkarma.com\/blog\/author\/jamesgallagher\/"}]}},"_links":{"self":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts\/12482","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/users\/240"}],"replies":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/comments?post=12482"}],"version-history":[{"count":0,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts\/12482\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/media\/12483"}],"wp:attachment":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/media?parent=12482"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/categories?post=12482"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/tags?post=12482"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}