Questions tagged as 'array'

1
answer

check the IP input with IP array

I want to check the IP input if it is inside any of the 3 or 4 array list I put the message, I had it like that but it does not work. $laptop=(1.1.1.1,2.2.2.2,3.3.3.3) $pcescritorio=(1.1.1.2,2.2.2.3,3.3.3.4) switch ($_SERVER['REMOTE_ADDR']) {...
asked by 13.05.2018 / 22:52
1
answer

Management of multidimensional codeigniter arrays

Good morning. I have an arrangement to save the information of the session that I will use, it is sent to me by multidimensional arrangement but I have not been able to access the data, I can only see them through print_r. Annex result of print_...
asked by 08.05.2018 / 20:29
1
answer

Save a file from an array () in laravel

I have the following result of a request for a view: array:10 [▼ "_token" => "safbCVoGYiCk4cpDPJmSCZDJF17YkgAg21DwT7Iu" "tipopersona" => "2" "empresa" => "3" "persona" => "3" "tsolicitud" => "1" "comentario" => "...
asked by 05.05.2018 / 02:25
2
answers

How to compare two different values in java? Example [+ and -]

What I want to do is compare to my current operator + or any other arithmetic operator with any of the operators that I have previously that are also arithmetic, I have 4+- , this here is wrong so I want to make it detect if ther...
asked by 25.04.2018 / 02:46
1
answer

Matrix reading sent by Socket JAVA

I can send an array from the Server Class to the Client class and read it, but I can not read a matrix. Where is the error? public class Client extends Thread { InetAddress host = null; Socket socket = null; ObjectOutputStream oos = null;...
asked by 21.04.2018 / 01:54
0
answers

Array in the Angular template

I have the following code in ts, where it shows a code, which is that, every time I click on a button; I will decrease an array and when there is only one array, do not erase it; but to show it for more than click on the button. removeCostCent...
asked by 30.04.2018 / 21:19
1
answer

Insert with several records with PDO PHP using a loop

I have this "add" function, which adds a product code 'X' in a table called "INVENTORIES", works well for me, but I want to add a fragment of code in PHP that I insert in a table called "PRECIOSXPROD" the product code for 'Y' times according to...
asked by 16.04.2018 / 21:30
0
answers

Complexity time of a circular array

I have a problem that tells me that I have an array of N comparable elements and an array b that is circular from a. And it asks me to design a generic function in Java that receives a circular array b of comparable elements and a t value of gen...
asked by 17.04.2018 / 00:09
1
answer

how to know the most repeated char within an array?

I need to know the most repeated char within an array Scanner var = new Scanner(System.in); String cad; System.out.println("escribe caracteres"); cad = var.nextLine(); char[] a = cad.toCharArray(); I do not stop there.     
asked by 21.04.2018 / 21:07
0
answers

Error in PHP, constant T_PAAMAYIM_NEKUDOTAYIM

PHP Code - SQLITE <?php include 'connection.php'; // base de datos donde tomar los datos $db_from = new dbProd(); // base de datos para insertar datos de la otra base de datoss $db_to = new dbEncuestas(); // Con los datos o no // $data =...
asked by 11.04.2018 / 19:54