View difference between Paste ID: xLj1SVhM and HRSG2mjt
SHOW: | | - or go back to the newest paste.
1
<?php
2
3-
$data = [
3+
class Mahasiswa
4-
    'id'         => 1,
4+
{
5-
    'nama'       => 'Aldino Kemal',
5+
    private $nim;
6-
    'age'        => 40,
6+
    private int $tahunMasuk = 2020;
7-
    'address'    => [
7+
    public string $nama = "Aldino Kemal";
8-
        'city'    => 'Yogyakarta',
8+
    protected string $alamat;
9-
        'country' => 'indonesia'
9+
}
10-
    ],
10+
11-
    'specialist' => ['php', 'golang', 'mysql'],
11+
12-
    'no_hp'      => [
12+
$mhs1 = new Mahasiswa();
13-
        [
13+
echo $mhs1->nama;
14-
            'number'   => '628968523123',
14+
var_dump($mhs1);