In invitation email i was noticed that 1 round will be coding interview and I could use stuff like LeetCode to prepare. Basically task below doesn't look like algorithmic task, but ok let's get down to the interview.
In the beggining interviwer started with repeating like a mantra that "it's pretty simple task" many times. Task desription confusing from the begging. As it has mix of bonus points and staight forward (simpliest) way to implement this. At the middle of the interview interviwer started to getting annoid with my questions because I didn't understand all the conditions and said like "man, look at the paper". One of the worst interview in my life.
We have freelancers who specialize in making landing pages. Each of them needs 2 days to make a standard landing page and works 5 days per week. They accept 3 types of contracts:
Type 1: Deliver a landing page in 2 work-weeks, for $300 USD Type 2: Deliver a landing page in 1 work-week, for $500 USD Type 3: Deliver a landing page in 3 work-days, for $1500 USD
In all cases, the landing page may be delivered earlier, but not later than required by the contract type.
Please implement the Freelancer class with 2 methods, as well as any supporting entities:
Method 1: Freelancer::receiveContract(contractType)
Example (in pseudocode):
receiveContract(Type3) > contract1//has no commitments, so can complete this contract
receiveContract(Type3) > error//already committed 2 days. remaining 1 day of dev time is not //enough to complete this contract receiveContract(Type1) > contract2//only committed 2 days. remaining 8 days of dev time is enough //to complete this contract workOnContract(contract2) > increments day//now 2 days before “contract1” is due - 2 days of work, 7 days //before “contract2” is due - 1 day of work workOnContract(contract2) > error//there are only 2 days remaining before “contract1” is due - //2 days of work workOnContract(contract1) > increments day//now 1 day before “contract1” is due - 1 day of work, 6 days // before “contract2” is due - 1 day of work workOnContract(contract1) > completes contract1 //now 5 days before “contract2” is due - 1 day of work > increments day
Bonus points: Support optionally marking a contract as “uninterruptable” - once the freelancer starts working on it, they have to work on it until completed. Support contract deadlines in calendar weeks, not work weeks. Take the current weekday into account.
The following metrics were computed from 1 interview experience for the Upwork Senior Software Engineer role in Georgia.
Upwork's interview process for their Senior Software Engineer roles in Georgia is extremely selective, failing the vast majority of engineers.
Candidates reported having very negative feelings for Upwork's Senior Software Engineer interview process in Georgia.