mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
array contains
This commit is contained in:
committed by
Christoffer Lerno
parent
946c167bf1
commit
434a0e8e4b
@@ -1,5 +1,12 @@
|
||||
module arraytests @test;
|
||||
|
||||
fn void contains()
|
||||
{
|
||||
int[3] a = { 1, 2, 3 };
|
||||
assert(array::contains(a, 2) == true);
|
||||
assert(array::contains(a, 15) == false);
|
||||
}
|
||||
|
||||
fn void find()
|
||||
{
|
||||
int[3] a = { 1, 2, 3 };
|
||||
|
||||
Reference in New Issue
Block a user