Engaged Employer
Hackerrank test: - Given entry and exit time in string format (e.g. entry: "9:42", exit: "11:07"). Find the parking price. Given were constant price, price for first hour and subsequent hours. - You are given a DTD for XML in the following format. <!ENTITY a1 10> -> a1 is a leaf tag occupying 1 one line. Integer followed by a1 means it's a leaf. <!ENTITY a2 a1;a1> -> a2 is a tag containing two a1 tags, thus occupying two lines. So, when expanded, the whole thing occupies 3 lines. Write a program that will take this definition in a vector<string> and calculates the number of lines in the expanded version (say count). Print "0 <count>" if the number of lines exceeded a given input L, otherwise print "1 <count>". Note: Consider the ordering as well. What if a2 contains a1 but a1 hasn't arrived yet?
Check out your Company Bowl for anonymous work chats.