Skip to content

Commit 76ec41e

Browse files
authored
Update Binary_Search.c
1 parent ddf3334 commit 76ec41e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

search/Binary_Search.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,13 @@ int main() {
66
int n_terms, *arr, item, i, j, mid, top, bottom;
77

88

9+
910
printf("Enter how many elements you want:\n"); // no of elements
1011
scanf("%d", &n_terms);
1112
arr = (int*)malloc(sizeof(int)*n_terms);
1213
printf("Enter the %d elements in ascending order\n", n_terms);
1314
for (i = 0; i < n_terms; i++) {
14-
scanf("%d", &arr[i]);
15+
scanf("%d", &arr[i]);
1516
}
1617

1718
printf("\nEnter the item to search\n"); // Target element to be searched

0 commit comments

Comments
 (0)