place into or between other items in an enumeration
Questions tagged [insertion]
578 questions
-4
votes
4 answers
Array size redefinition
So basically according to definition of array we cannot change array size. But if I am adding element to a same array by shifting other elements to the right of array, so the array size is going to increase.
How this is…

ALMAS SANGLE
- 23
- 1
- 7
-4
votes
1 answer
Validation not working in PHP on submission the form data by click the submit button
Validation not working in php on submission the form data by click the submit button.

Ajay kumar
- 1
- 3
-4
votes
1 answer
Java insertion sort not working properly
enter image description here
This is the code screenshot link.
I am edit many time but every time the output is not completely sorted.

Vikash kumar
- 7
- 1
-4
votes
1 answer
heap sort may be considered as insertion sort or selection sort done on a heap data structure instead of a list? Which one will it be?
Heap sort may be considered
as
A. Insertion sort done on a heap data structure instead of a list.
B. Selection sort done on a heap data structure instead of a list.
C. Bubble sort done on a heap data structure instead of a list.
D. None of the…
-4
votes
2 answers
implement binary tree and make it balanced
how to do insert random integer between 1 and 10000 to the tree?? I just using scanner.in in code below
private BinaryTree insert(BinaryTree node, int value)
{
if (node == null)
node = new BinaryTree(value);
else
{
…

Sarina badiei
- 1
- 1
-4
votes
1 answer
why mergeSort faster than insertion in java
I wrote a code in java using int insertion and int mergeSort. also
String insertion and String mergeSort. my question is why mergeSort always faster?

user3222289
- 31
- 5
-5
votes
1 answer
Incrementing at j even though it doesn't meet the condition
public class sorting {
public static void sort(int arr[]) {
int n = arr.length;
int count = 0;
int tempArr [] = arr.clone();
// One by one move boundary of unsorted subarray
for (int i = 0; i < n-1;…

Elsa Zone
- 1
- 1
-6
votes
1 answer
Python "int is not subscriptable" error
Why isn't this working?
It says int is not subscriptable when I run speedtest.
This is the error:
Traceback (most recent call last):
File "", line 1, in
speedtest()
File…