 
 extension ViewController: ExpandableDelegate {
     func expandableTableView(_ expandableTableView: ExpandableTableView, expandedCellsForRowAt indexPath: IndexPath) -> [UITableViewCell]? {
-        guard let cell = expandableTableView.dequeueReusableCell(withIdentifier: ExpandedCell.ID) else { return [UITableViewCell]() }
-        guard let cell2 = expandableTableView.dequeueReusableCell(withIdentifier: ExpandedCell.ID) else { return [UITableViewCell]() }
-        guard let cell3 = expandableTableView.dequeueReusableCell(withIdentifier: ExpandedCell.ID) else { return [UITableViewCell]() }
-
-        var cells = [UITableViewCell]()
-
         switch indexPath.section {
         case 0:
             switch indexPath.row {
             case 0:
-                cells.append(cell)
-                cells.append(cell2)
-                cells.append(cell3)
-                return cells
+                return [cell, cell, cell]
                 
             case 2:
-                cells.append(cell)
-                cells.append(cell2)
-                return cells
+                return [cell, cell]
             case 3:
-                cells.append(cell)
-                return cells
+                return [cell]
 
             default:
                 break

    }
    
    func expandableTableView(_ expandableTableView: ExpandableTableView, heightsForExpandedRowAt indexPath: IndexPath) -> [CGFloat]? {
        var heights = [CGFloat]()

        switch indexPath.section {
        case 0:
            switch indexPath.row {
            case 0:
                let height: CGFloat = 44
                heights.append(height)
                heights.append(height)
                heights.append(height)
                return heights
                
            case 2:
                let height: CGFloat = 33
                heights.append(height)
                heights.append(height)
                return heights
                
            case 3:
                let height: CGFloat = 22
                heights.append(height)
                return heights

            default:
                break

class ViewController: UIViewController {
    @IBOutlet weak var tableView: ExpandableTableView!

    var cell: UITableViewCell {
        return tableView.dequeueReusableCell(withIdentifier: ExpandedCell.ID)!
    }
    
    override func viewDidLoad() {
        super.viewDidLoad()
        
