[ create a new paste ] login | about

Link: http://codepad.org/MC6h5cFM    [ raw code | output | fork ]

PHP, pasted on Dec 3:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php

	$a = array(
			array('1','11'),
			array('2','22'),
			array('3','33'),
			array('4','44'),
	);
	
	$b = array(
			array('2','22'),
			array('3','33')
	);


	foreach ($a as $v)
	{
		in_array($v, $b) ? print("1 ") : print("0 ");
	}

?>


Output:
1
0 1 1 0 


Create a new paste based on this one


Comments: