Skip to main content

Goldman Sachs Interview Experience

· One min read
Sujith

First Round

i was asked one dsa question which is zigzag conversion of string https://leetcode.com/problems/zigzag-conversion/

Second Round

A Node is defined as a directory or file. If its a directory it can have sub-directories and files inside it. Write a function `deleteNode` which deletes the node and its childern recursively Given to you three functions/methods
  1. isDirectory which returns if the node is a directory or not
  2. getChildren if the node is a directory, and not empty returns all the contents inside it
  3. delete deletes the node if its a file or if an empty directory