{"id":150,"date":"2018-12-05T20:44:28","date_gmt":"2018-12-05T12:44:28","guid":{"rendered":"http:\/\/h-k.pw\/?p=150"},"modified":"2018-12-10T16:15:15","modified_gmt":"2018-12-10T08:15:15","slug":"c-function-summary","status":"publish","type":"post","link":"https:\/\/harson.co\/index.php\/2018\/12\/05\/c-function-summary\/","title":{"rendered":"C Function Summary"},"content":{"rendered":"<pre class=\"pure-highlightjs\"><code class=\"\">#include &lt;stdio.h&gt;\r\n#include &lt;math.h&gt;\r\n\r\n\r\nint isPrime(int n)\r\n{\r\n    for (int i = 2; i &lt;= sqrt(n) ; i++)\r\n    {\r\n        if (n % i == 0)\r\n            return 0;\r\n    }\r\n    return 1;\r\n}\r\n\r\nint isLeapYear(int n)\r\n{\r\n    if(n%4==0 &amp;&amp; n%100!=0 &amp;&amp; n%400==0)\r\n\treturn 1;\r\n    else\r\n\treturn 0;\r\n}\r\n\r\nint ifRepeat(int ar[],int len)\r\n{\r\n\tint z,x,c;\r\n\t\r\n\tfor(int j=0;j&lt;len;j++)\r\n   {\r\n      z =0;\r\n      for(int x=0;x&lt;len;x++)\r\n      {\r\n          if(x==j)\r\n              continue;\r\n\r\n          if(ar[j]==ar[x])\r\n              return 1;\r\n      }\r\n   }\r\n\treturn 0;\t\r\n}\r\n\r\n\r\n\r\nint Len(int arr[])\r\n{\r\n  length = sizeof(arr) \/ sizeof(int); \r\n  return length;\r\n}\r\n<\/code><\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>#include &lt;stdio.h&gt; #include &lt;math.h&gt; int is [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-150","post","type-post","status-publish","format-standard","hentry","category-pta"],"_links":{"self":[{"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/posts\/150","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/comments?post=150"}],"version-history":[{"count":4,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/posts\/150\/revisions"}],"predecessor-version":[{"id":160,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/posts\/150\/revisions\/160"}],"wp:attachment":[{"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/media?parent=150"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/categories?post=150"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/harson.co\/index.php\/wp-json\/wp\/v2\/tags?post=150"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}