{"id":4936,"date":"2022-08-25T05:56:44","date_gmt":"2022-08-25T00:26:44","guid":{"rendered":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/"},"modified":"2022-08-25T05:56:44","modified_gmt":"2022-08-25T00:26:44","slug":"solved-count-the-os-from-a-given-string-sayxooo","status":"publish","type":"post","link":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/","title":{"rendered":"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;"},"content":{"rendered":"<p> [ad_1]<br \/>\n<\/p>\n<div id=\"answer-25486379\" class=\"answer js-answer accepted-answer js-accepted-answer\" data-answerid=\"25486379\" data-parentid=\"25474272\" data-score=\"0\" data-position-on-page=\"1\" data-highest-scored=\"1\" data-question-has-accepted-highest-score=\"1\" itemprop=\"acceptedAnswer\" itemscope itemtype=\"https:\/\/schema.org\/Answer\">\n<div class=\"post-layout\">\n<div class=\"votecell post-layout--left\"><\/div>\n<div class=\"answercell post-layout--right\">\n<div class=\"s-prose js-post-body\" itemprop=\"text\">\n<p>The problem with your code is this check:<\/p>\n<pre><code>if (ch == 'O') {\n    if (!((inp.charAt(i + 1)) == 'X' || (inp.charAt(i - 1)) == 'X')) {\n        count++\n    }\n}\n<\/code><\/pre>\n<p>Here you check for only a case where there is O not surrounded by X. But this check doesn&#8217;t work for cases like *OOXOO*. You&#8217;ll get 2 but the result is 0. So the solution is to do it in loop or using regexp. Examples are shown below.<\/p>\n<p>Also you did that:<\/p>\n<pre><code>inp = \".\" + inp + \".\";\n<\/code><\/pre>\n<p>which I think is not needed. I&#8217;m guessing you did that because you were getting <code>ArrayIndexOutOfBoundsException<\/code> while looping for <code>i = 0<\/code>. The solution you proposed works, but you could also add check in the loop for <code>(i&gt;0)<\/code> or start from 1 and check behind + front (see examples below).<\/p>\n<p>If you don&#8217;t require a loop with array then you can use a simple regex:<\/p>\n<pre><code>testString = testString.replaceAll(\"[O]+X\",\"X\").replaceAll(\"X[O]+\", \"X\");\n<\/code><\/pre>\n<p>The whole test-program:<\/p>\n<pre><code>public class Main {\n\n    public static void main(final String args[]) throws IOException\n    {\n        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n        System.out.print(\"Enter Test String: \");\n        String testString = br.readLine();\n        testString = \".\" + testString + \".\";\n\n        testString = testString.replaceAll(\"[O]+X\",\"X\").replaceAll(\"X[O]+\", \"X\");\n\n        int count = testString.length() - testString.replace(\"O\", \"\").length();\n        System.out.println(\"Result string:  \" + testString);\n        System.out.println(\"Total 'O' left:  \" + count);\n    }\n}\n<\/code><\/pre>\n<p><strong>Test1:<\/strong><\/p>\n<pre><code>Enter Test String: *OOX*XOX*OO*XO*O*X*OX*XO*O*\nResult string:  .*X*XX*OO*X*O*X*X*X*O*.\nTotal 'O' left:  4\n<\/code><\/pre>\n<p><strong>Test2:<\/strong><\/p>\n<pre><code>Enter Test String: *OOXOO*OO\nResult string:  .*X*OO.\nTotal 'O' left:  2\n<\/code><\/pre>\n<p><strong>Test3:<\/strong><\/p>\n<pre><code>Enter Test String: *O*OXOO*OO\nResult string:  .*O*X*OO.\nTotal 'O' left:  3\n<\/code><\/pre>\n<p><strong>EDIT<\/strong><br \/>\nBelow there are 3 types of solutions to your problem:<\/p>\n<pre><code>public class Main {\n\n    private BufferedReader userInput;\n    private String testString;\n\n    public static void main(final String args[])\n    {\n        BufferedReader userInput = new BufferedReader(new InputStreamReader(System.in));  \/\/get the reader.\n        Main test = new Main(userInput); \/\/create an object of a test class that will use this reader\n        test.getTestString(); \/\/ask user for the input\n        test.removeOsWithRegex();  \/\/first method - regex\n        test.removeOsByReplacingWithX(); \/\/second method - in loop change all O's to X's\n        test.removeOsByInLoopDeletion(); \/\/third method - delete all O's step by step in a loop.\n    }\n\n    public Main(final BufferedReader userInput)\n    {\n        this.userInput = userInput;  \/\/constructor\n    }\n\n    \/\/getting the test string.\n    private void getTestString()\n    {\n        System.out.print(\"Enter Test String: \");\n        try\n        {\n            testString = userInput.readLine();\n            testString = \".\" + testString + \".\";\n        }\n        catch (IOException e)\n        {\n            throw new IllegalStateException(\"Something wrong happened: \" + e.getMessage() + \". Shutting down.\");\n        }\n    }\n\n    \/\/removing with regex\n    private void removeOsWithRegex()\n    {\n        System.out.println(\"Removing 'O' with regexp from: \" + testString);\n\n        \/\/change all parts of testString where there are Os followed by X to X.\n        \/\/do the same with parts of testString where there is X followed by one or more O.\n        String resultString = testString.replaceAll(\"[O]+X\",\"X\").replaceAll(\"X[O]+\", \"X\");\n        \/\/the number of Os is the length of the string minus length of the string without Os.\n        int count = resultString.length() - resultString.replace(\"O\", \"\").length();\n        System.out.println(\"Result string:  \" + resultString);\n        System.out.println(\"Total 'O' left:  \" + count);\n    }\n\n    \/\/2nd method\n    public void removeOsByReplacingWithX()\n    {\n        System.out.println(\"Removing 'O' by replacing them with X: \" + testString);\n\n        byte[] byteArray = testString.getBytes();\n        boolean changesMade;\n        \/\/create loop\n        do\n        {\n            changesMade = false;\n            for (int i = 1; i &lt; byteArray.length - 1; i++)\n            {\n                \/\/if X was found change adjacent Os to X\n                if (byteArray[i] == 'X')\n                {\n                    if (byteArray[i-1] == 'O')\n                    {\n                        byteArray[i-1] = 'X';\n                        changesMade = true;\n                    }\n                    if (byteArray[i+1] == 'O')\n                    {\n                        byteArray[i+1] = 'X';\n                        changesMade = true;\n                    }\n                }\n            }\n        } while(changesMade);  \/\/do this as long as there is something to change.\n\n        String resultString = new String(byteArray);\n\n        int count = resultString.length() - resultString.replace(\"O\", \"\").length();\n        System.out.println(\"Result string:  \" + resultString);\n        System.out.println(\"Total 'O' left:  \" + count);\n    }\n\n\n    \/\/3rd method\n    public void removeOsByInLoopDeletion()\n    {\n        System.out.println(\"Removing 'O' by deleting them in loop: \" + testString);\n\n        byte[] byteArray = testString.getBytes();\n        boolean changesMade;\n        \/\/create a loop\n        do\n        {\n            changesMade = false;\n            for (int i = 1; i &lt; byteArray.length - 1; i++)\n            {\n                \/\/if there is X\n                if (byteArray[i] == 'X')\n                {\n                    \/\/if next is O then shorten the array by cutting the O\n                    if (byteArray[i+1] == 'O')\n                    {\n                        byteArray = shortenByteArray(byteArray, i+1); \/\/i+1 is the position of O\n                        changesMade = true;\n                        break;\n                    }\n                }\n                \/\/on the other hand if O was wound\n                if (byteArray[i] == 'O')\n                {\n                    \/\/if X is next, shorten it by cutting O from current position\n                    if (byteArray[i+1] == 'X')\n                    {\n                        byteArray = shortenByteArray(byteArray, i); \/\/i is current position.\n                        changesMade = true;\n                        break;\n                    }\n                }\n            }\n        } while(changesMade);\n\n        String resultString = new String(byteArray);\n\n        int count = resultString.length() - resultString.replace(\"O\", \"\").length();\n        System.out.println(\"Result string:  \" + resultString);\n        System.out.println(\"Total 'O' left:  \" + count);\n    }\n\n    \/\/cutting one element from byte array\n    private byte[] shortenByteArray(final byte[] byteArray, final Integer startIndex)\n    {\n        byte[] newByteArray = new byte[byteArray.length-1];\n        for (int i = 0; i &lt; newByteArray.length; i++)\n        {\n            \/\/rewrite all before the item to cut\n            if (i &lt; startIndex)\n            {\n                newByteArray[i] = byteArray[i];\n            }\n            else\n            {\n                \/\/ommit the element to cut and move all others by 1.\n                newByteArray[i] = byteArray[i+1];\n            }\n        }\n        return newByteArray;\n    }\n}\n<\/code><\/pre>\n<p>The results are the same for all three cases for all 3 tests I&#8217;ve supplied earlier.<\/p>\n<\/p><\/div>\n<div class=\"mt24\"><\/div>\n<\/div>\n<p>            <span class=\"d-none\" itemprop=\"commentCount\">3<\/span> <\/p><\/div>\n<\/div>\n<p>[ad_2]<\/p>\n<p>solved Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221; <\/p>\n","protected":false},"excerpt":{"rendered":"<p>[ad_1] The problem with your code is this check: if (ch == &#8216;O&#8217;) { if (!((inp.charAt(i + 1)) == &#8216;X&#8217; || (inp.charAt(i &#8211; 1)) == &#8216;X&#8217;)) { count++ } } Here you check for only a case where there is O not surrounded by X. But this check doesn&#8217;t work for cases like *OOXOO*. You&#8217;ll &#8230; <a title=\"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;\" class=\"read-more\" href=\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\" aria-label=\"More on [Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[320],"tags":[323],"class_list":["post-4936","post","type-post","status-publish","format-standard","hentry","category-solved","tag-java"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>[Solved] Count the O&#039;s from a Given String, say=&quot;*XOO*O&quot; - JassWeb<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"[Solved] Count the O&#039;s from a Given String, say=&quot;*XOO*O&quot; - JassWeb\" \/>\n<meta property=\"og:description\" content=\"[ad_1] The problem with your code is this check: if (ch == &#039;O&#039;) { if (!((inp.charAt(i + 1)) == &#039;X&#039; || (inp.charAt(i - 1)) == &#039;X&#039;)) { count++ } } Here you check for only a case where there is O not surrounded by X. But this check doesn&#8217;t work for cases like *OOXOO*. You&#8217;ll ... Read more\" \/>\n<meta property=\"og:url\" content=\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\" \/>\n<meta property=\"og:site_name\" content=\"JassWeb\" \/>\n<meta property=\"article:published_time\" content=\"2022-08-25T00:26:44+00:00\" \/>\n<meta name=\"author\" content=\"Kirat\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Kirat\" \/>\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:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\"},\"author\":{\"name\":\"Kirat\",\"@id\":\"https:\/\/jassweb.com\/solved\/#\/schema\/person\/65c9c7b7958150c0dc8371fa35dd7c31\"},\"headline\":\"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;\",\"datePublished\":\"2022-08-25T00:26:44+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\"},\"wordCount\":178,\"publisher\":{\"@id\":\"https:\/\/jassweb.com\/solved\/#organization\"},\"keywords\":[\"java\"],\"articleSection\":[\"Solved\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\",\"url\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\",\"name\":\"[Solved] Count the O's from a Given String, say=\\\"*XOO*O\\\" - JassWeb\",\"isPartOf\":{\"@id\":\"https:\/\/jassweb.com\/solved\/#website\"},\"datePublished\":\"2022-08-25T00:26:44+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/jassweb.com\/solved\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/jassweb.com\/solved\/#website\",\"url\":\"https:\/\/jassweb.com\/solved\/\",\"name\":\"JassWeb\",\"description\":\"Build High-quality Websites\",\"publisher\":{\"@id\":\"https:\/\/jassweb.com\/solved\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/jassweb.com\/solved\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/jassweb.com\/solved\/#organization\",\"name\":\"Jass Web\",\"url\":\"https:\/\/jassweb.com\/solved\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/jassweb.com\/solved\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/jassweb.com\/wp-content\/uploads\/2021\/02\/jass-website-logo-1.png\",\"contentUrl\":\"https:\/\/jassweb.com\/wp-content\/uploads\/2021\/02\/jass-website-logo-1.png\",\"width\":693,\"height\":132,\"caption\":\"Jass Web\"},\"image\":{\"@id\":\"https:\/\/jassweb.com\/solved\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/jassweb.com\/solved\/#\/schema\/person\/65c9c7b7958150c0dc8371fa35dd7c31\",\"name\":\"Kirat\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/jassweb.com\/solved\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/jassweb.com\/solved\/wp-content\/litespeed\/avatar\/1261af3c9451399fa1336d28b98ea3bb.jpg?ver=1775798750\",\"contentUrl\":\"https:\/\/jassweb.com\/solved\/wp-content\/litespeed\/avatar\/1261af3c9451399fa1336d28b98ea3bb.jpg?ver=1775798750\",\"caption\":\"Kirat\"},\"sameAs\":[\"http:\/\/jassweb.com\"],\"url\":\"https:\/\/jassweb.com\/solved\/author\/jaspritsinghghumangmail-com\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"[Solved] Count the O's from a Given String, say=\"*XOO*O\" - JassWeb","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:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/","og_locale":"en_US","og_type":"article","og_title":"[Solved] Count the O's from a Given String, say=\"*XOO*O\" - JassWeb","og_description":"[ad_1] The problem with your code is this check: if (ch == 'O') { if (!((inp.charAt(i + 1)) == 'X' || (inp.charAt(i - 1)) == 'X')) { count++ } } Here you check for only a case where there is O not surrounded by X. But this check doesn&#8217;t work for cases like *OOXOO*. You&#8217;ll ... Read more","og_url":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/","og_site_name":"JassWeb","article_published_time":"2022-08-25T00:26:44+00:00","author":"Kirat","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Kirat","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#article","isPartOf":{"@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/"},"author":{"name":"Kirat","@id":"https:\/\/jassweb.com\/solved\/#\/schema\/person\/65c9c7b7958150c0dc8371fa35dd7c31"},"headline":"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;","datePublished":"2022-08-25T00:26:44+00:00","mainEntityOfPage":{"@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/"},"wordCount":178,"publisher":{"@id":"https:\/\/jassweb.com\/solved\/#organization"},"keywords":["java"],"articleSection":["Solved"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/","url":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/","name":"[Solved] Count the O's from a Given String, say=\"*XOO*O\" - JassWeb","isPartOf":{"@id":"https:\/\/jassweb.com\/solved\/#website"},"datePublished":"2022-08-25T00:26:44+00:00","breadcrumb":{"@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/jassweb.com\/solved\/solved-count-the-os-from-a-given-string-sayxooo\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/jassweb.com\/solved\/"},{"@type":"ListItem","position":2,"name":"[Solved] Count the O&#8217;s from a Given String, say=&#8221;*XOO*O&#8221;"}]},{"@type":"WebSite","@id":"https:\/\/jassweb.com\/solved\/#website","url":"https:\/\/jassweb.com\/solved\/","name":"JassWeb","description":"Build High-quality Websites","publisher":{"@id":"https:\/\/jassweb.com\/solved\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/jassweb.com\/solved\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/jassweb.com\/solved\/#organization","name":"Jass Web","url":"https:\/\/jassweb.com\/solved\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/jassweb.com\/solved\/#\/schema\/logo\/image\/","url":"https:\/\/jassweb.com\/wp-content\/uploads\/2021\/02\/jass-website-logo-1.png","contentUrl":"https:\/\/jassweb.com\/wp-content\/uploads\/2021\/02\/jass-website-logo-1.png","width":693,"height":132,"caption":"Jass Web"},"image":{"@id":"https:\/\/jassweb.com\/solved\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/jassweb.com\/solved\/#\/schema\/person\/65c9c7b7958150c0dc8371fa35dd7c31","name":"Kirat","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/jassweb.com\/solved\/#\/schema\/person\/image\/","url":"https:\/\/jassweb.com\/solved\/wp-content\/litespeed\/avatar\/1261af3c9451399fa1336d28b98ea3bb.jpg?ver=1775798750","contentUrl":"https:\/\/jassweb.com\/solved\/wp-content\/litespeed\/avatar\/1261af3c9451399fa1336d28b98ea3bb.jpg?ver=1775798750","caption":"Kirat"},"sameAs":["http:\/\/jassweb.com"],"url":"https:\/\/jassweb.com\/solved\/author\/jaspritsinghghumangmail-com\/"}]}},"_links":{"self":[{"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/posts\/4936","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/comments?post=4936"}],"version-history":[{"count":0,"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/posts\/4936\/revisions"}],"wp:attachment":[{"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/media?parent=4936"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/categories?post=4936"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jassweb.com\/solved\/wp-json\/wp\/v2\/tags?post=4936"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}