GunturGongura Posted February 12, 2016 Author Report Share Posted February 12, 2016 I didnot work in python... but ..the thing is use any language.... but print powerset ade problem try cheyi Ok Link to comment Share on other sites More sharing options...
uncertainity Posted February 12, 2016 Report Share Posted February 12, 2016 Any java,J2ee,advanced java guys?? Link to comment Share on other sites More sharing options...
pandugadu999 Posted February 12, 2016 Report Share Posted February 12, 2016 ee coding ki oka dandam ra babu.. Link to comment Share on other sites More sharing options...
chaikumar Posted February 12, 2016 Report Share Posted February 12, 2016 ok ya …..kani python lo list untundi..like[1,2,3,5] subsets are[1],[2]….[1,2,3,5] e {1} notation ni emantaru python lo? these flower brackets basically are dictionaries with key and value Link to comment Share on other sites More sharing options...
chaikumar Posted February 12, 2016 Report Share Posted February 12, 2016 ok ya …..kani python lo list untundi..like[1,2,3,5] subsets are[1],[2]….[1,2,3,5] e {1} notation ni emantaru python lo? these flower brackets basically are dictionaries with key and value Link to comment Share on other sites More sharing options...
username1 Posted February 12, 2016 Report Share Posted February 12, 2016 GP Link to comment Share on other sites More sharing options...
k2s Posted February 12, 2016 Report Share Posted February 12, 2016 Will try eveningjust checking... Evening ayindi... Link to comment Share on other sites More sharing options...
puli_keka Posted February 12, 2016 Report Share Posted February 12, 2016 just checking... Evening ayindi... It's still 1:40 no just came back from lunch Link to comment Share on other sites More sharing options...
k2s Posted February 12, 2016 Report Share Posted February 12, 2016 It's still 1:40 no just came back from lunch antey... TS EST emo kada.. Akkada evening ayindi kada ani Link to comment Share on other sites More sharing options...
errigaadu Posted February 12, 2016 Report Share Posted February 12, 2016 Link to comment Share on other sites More sharing options...
GunturGongura Posted February 12, 2016 Author Report Share Posted February 12, 2016 ok ya …..kani python lo list untundi..like[1,2,3,5] subsets are[1],[2]….[1,2,3,5] e {1} notation ni emantaru python lo? these flower brackets basically are dictionaries with key and value Entidi Link to comment Share on other sites More sharing options...
chaikumar Posted February 12, 2016 Report Share Posted February 12, 2016 Entidi I was driving and accidentally hit reply button. He just gave an example for output, showing with curly braces. You can use lists or sets in python to store these subsets and then print them. Link to comment Share on other sites More sharing options...
rikki Posted February 12, 2016 Report Share Posted February 12, 2016 Output: 1, 2, 3, 5, 1, 2, 1, 3, 1, 5, 2, 2, 2, 3, 2, 5, 3, 2, 3, 3, 3, 5, 1, 2, 3, 1, 2, 5, 1, 3, 3, 1, 3, 5, 2, 2, 3, 2, 2, 5, 2, 3, 3, 2, 3, 5, problem enti ante 1,3, 3 kuda printing...aa print statement lo distinct unte ne print cheyi anali..like print[j]< print[j+1[ public void SubSetsMain() { int[] arr = new int[4]{1,2,3,5}; int[] printarr = new int[arr.Length]; int index =0; for (int i = 0; i < arr.Length; i++) { FindSubSets(arr, 0, arr.Length, i, printarr, index); } Console.ReadLine(); } public void FindSubSets(int[] arr, int start, int end, int numberofelements, int[] printarr, int index) { if (numberofelements == 0) { for (int j = 0; j < index; j++) Console.Write(printarr[j] + ", "); Console.WriteLine(); return; } for(int i = start; i<= end - numberofelements; i++) { printarr[index] = arr[i]; FindSubSets(arr, start + 1, end, numberofelements-1, printarr, index + 1); } } given input : {1,2,3,5} subsets are print output: {1}{2}{3}{5} {1,2}{1,3}{1,5}{2,3}{2,5}{2,5}{3,5} {1,2,3}{1,2,5}{1,3,5}{2,3,5} {1,2,3,5} ================================================ sum vishayaniki vosthe .. prathi dhani sum print cheyal anthe..... Link to comment Share on other sites More sharing options...
uncertainity Posted February 15, 2016 Report Share Posted February 15, 2016 Huffman coding ..practice for today Link to comment Share on other sites More sharing options...
GunturGongura Posted February 15, 2016 Author Report Share Posted February 15, 2016 Uncertainity Kasta interview guide chey for ms students for entry level n interns Em adgutaru Link to comment Share on other sites More sharing options...
Recommended Posts