<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: number combinations using sas in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129714#M26463</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;length all $ 5;&lt;/P&gt;&lt;P&gt;&amp;nbsp; do i=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; do j=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; do k=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; do l=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; do m=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp; all=cats(i,j,k,l,m);&lt;/P&gt;&lt;P&gt;&amp;nbsp; output;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; keep all;&lt;/P&gt;&lt;P&gt;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&amp;nbsp; proc print;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 25 Sep 2012 00:09:02 GMT</pubDate>
    <dc:creator>Linlin</dc:creator>
    <dc:date>2012-09-25T00:09:02Z</dc:date>
    <item>
      <title>number combinations using sas</title>
      <link>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129713#M26462</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to get all possible 5 digit combinations of numbers starting from 0 to 4. I am not sure how to start or if it is doable. Has anybody done something like this before? Thanks in advance for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is what i am looking for&lt;/P&gt;&lt;P&gt;00000&lt;/P&gt;&lt;P&gt;00001&lt;/P&gt;&lt;P&gt;00002&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;44442&lt;/P&gt;&lt;P&gt;44443&lt;/P&gt;&lt;P&gt;44444&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Sep 2012 23:52:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129713#M26462</guid>
      <dc:creator>vicky07</dc:creator>
      <dc:date>2012-09-24T23:52:38Z</dc:date>
    </item>
    <item>
      <title>Re: number combinations using sas</title>
      <link>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129714#M26463</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;data have;&lt;/P&gt;&lt;P&gt;length all $ 5;&lt;/P&gt;&lt;P&gt;&amp;nbsp; do i=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; do j=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; do k=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; do l=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; do m=0 to 4;&lt;/P&gt;&lt;P&gt;&amp;nbsp; all=cats(i,j,k,l,m);&lt;/P&gt;&lt;P&gt;&amp;nbsp; output;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; end;&lt;/P&gt;&lt;P&gt;&amp;nbsp; keep all;&lt;/P&gt;&lt;P&gt;&amp;nbsp; run;&lt;/P&gt;&lt;P&gt;&amp;nbsp; proc print;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Sep 2012 00:09:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129714#M26463</guid>
      <dc:creator>Linlin</dc:creator>
      <dc:date>2012-09-25T00:09:02Z</dc:date>
    </item>
    <item>
      <title>Re: number combinations using sas</title>
      <link>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129715#M26464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want numbers :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;data test(keep=x);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;format x z5.;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;digits=5;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;base=5;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;do i = 0 to base**digits-1;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; x = 0;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; y = i;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; do j = 1 to digits;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; x = x + mod(y,base)*10**(j-1);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; y = int(y/base);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; output;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 12pt; font-family: calibri, verdana, arial, sans-serif;"&gt;run;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PG&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Sep 2012 01:43:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129715#M26464</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2012-09-25T01:43:12Z</dc:date>
    </item>
    <item>
      <title>Re: number combinations using sas</title>
      <link>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129716#M26465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Both answers worked. Thank you so much!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Sep 2012 04:13:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/number-combinations-using-sas/m-p/129716#M26465</guid>
      <dc:creator>vicky07</dc:creator>
      <dc:date>2012-09-25T04:13:54Z</dc:date>
    </item>
  </channel>
</rss>

