samples

struct Matrix {

    rows: usize,
    columns: usize,
    data: Vec<T>,

}

impl Matrix {

fn new(rows: usize, columns: usize) -> Self {

    Self {

        rows: rows,
        columns: columns,
        data: Vec::with_capacity(rows*columns),

    }

}

}

ngc matrix { <- ngc:container:capacity .storage

ngc:size rows
ngc:size columns 
ngc:many<ngc:data> 

}

ngc many { ngl:data }

ngc array { ngc:many; }

ng matrix { ngc:size ng:int ngc:many ng:vector }

ng:matrix{ rows = 2, cols = 2 }

ng:matrix m;

ngc integer {

}

Last updated