### Write a function flatten() which flattens this linked list with each node down sorted link list to a single link list with all the elements in sorted order.

We have given Two methods in O(n^2)

Interview Questions asked in Google, Microsoft, Amazon

by Dhaval Dave

We have given Two methods in O(n^2)

by Dhaval Dave

We have an array in which random integers are there. we need to find Pythagorean triplets.

which solves equation a^2 + b^2 = c^2.

**Method 1 : Brute Force **

which solves equation a^2 + b^2 = c^2.

by Dhaval Dave

**Method 1 (Brute Force Method)**

We can consider all substrings.

One by one and check for each substring whether it contains all unique characters or not.

There

by Dhaval Dave

Online Round Coding Question:

**Q1. Given a float number 7.64, convert it into the string WITHOUT using any inbuilt function/library.**

for eg:

input

float no.: 7.64

output

string:

by Dhaval Dave

Given a float number convert it into the string WITHOUT using any inbuilt Function

Method 1:

class Float2String { public static void main(String[] args) { float f=7.64f; String

by Dhaval Dave

1) Keep a Min & Max Heap of K size 2) Store first K elements

by Dhaval Dave

There are several ways to find loop in singly linked list,

Loop Node5 Next pointer is point to Node3 in Singly Linked List 1 ---- 2 ---- 3 ---- 4 ---- 5 |_____________|

- Hashmap
- Floyd’s