mirror of
https://hub.njuu.cf/TheAlgorithms/C-Plus-Plus.git
synced 2023-10-11 13:05:55 +08:00
Update searching_of_element_in_dynamic_Array.cpp
This commit is contained in:
parent
a3268742f3
commit
3621d2ee26
@ -33,12 +33,13 @@ The element is 5
|
||||
*/
|
||||
#include <iostream>
|
||||
int main() {
|
||||
long long int r, mr = 0, x, q, i, z;
|
||||
int64_t r, mr = 0, x, q, i, z;
|
||||
std::cout << "Enter Number of array you want to Store :";
|
||||
std::cin >> x;
|
||||
std::cout << "Enter Number of Question or Quary you want to do Related to Array :";
|
||||
std::cin >> q;
|
||||
//create a Array in run time because use can change the size of each array which he/she is going to store
|
||||
// create a Array in run time because use can
|
||||
// change the size of each array which he/she is going to store
|
||||
// create a 2D array
|
||||
int** ar = new int* [x]();
|
||||
for (r = 0; r < x; r++) {
|
||||
@ -55,7 +56,7 @@ std::cin >> ac[i];
|
||||
ar[r] = ac;
|
||||
}
|
||||
for (z = 0; z < q; z++) {
|
||||
long int r1 = 0, q1 = 0;
|
||||
int64_t r1 = 0, q1 = 0;
|
||||
std::cout << "enter the number of row which element You want to find :";
|
||||
std::cin >> r1;
|
||||
r1 = r1 - 1;
|
||||
|
Loading…
Reference in New Issue
Block a user