Jump to content
View in the app

A better way to browse. Learn more.

Andhrafriends.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Code Cleanliness Ante Enti

Featured Replies

  • Author

I didnot work in python... but ..the thing is use any language....
but print powerset ade problem try cheyi

Ok
  • Replies 64
  • Views 3.6k
  • Created
  • Last Reply

Top Posters In This Topic

Any java,J2ee,advanced java  guys?? 

ee coding ki oka dandam ra babu..

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

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

GP

Will try evening

just checking... Evening ayindi...

just checking... Evening ayindi...

It's still 1:40 no just came back from lunch -1xsWM.gif

It's still 1:40 no just came back from lunch -1xsWM.gif

antey... TS EST emo kada.. Akkada evening ayindi kada ani

-1xsWM.gif

  • Author

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

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.

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.....

 

Huffman coding ..practice for today

  • Author

Uncertainity


Kasta interview guide chey for ms students for entry level n interns

Em adgutaru

Account

Navigation

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.