Stack Min

It is Monday evening. Yesterday, with the help of my wife we cleaned a spot in my home office and put together the 4K monitor and computer. Later I set up the computer. The monitor is impressive. The only this missing for today is to connect the Azure Kinect DK and start experimenting.

Today I solved (at least I think) the 3.2 question Stack Min from the book “Cracking the Coding Interview”. The question follows:  “How would you design a stack which, in addition to push and pop, has a function min which returns the minimum element. As I am reading the question I want to state that when I was solving the problem, I agreed with the imaginary interviewer that min function would return the min value. We could also have the solution return the minimum element (the actual node), but we decided that that was not the scope of the question. Continue reading “Stack Min”

13 to 15 Java Questions

I have noticed that multiple times in a week I wake up and check my phone for the time and it is 04:47 AM. Given that I live in the Twin Cities of Minneapolis and St. Paul, there is some day light at that time. I recall a few years ago when I would get up around 05:00 AM to walk the dogs.

I do have an alarm set for 05:00 AM 7 days a week. In addition I have set an appointment in my Google calendar for the same time. Today after waking up at 04:47 AM I checked the calendar to see if there was a message or notification set for 15 minutes before (04:45 AM). Both notification and email are set for 05:00 AM. Continue reading “13 to 15 Java Questions”

Valid Parentheses

I have not solved a LeetCode challenge in a couple weeks. Went to the site and the system suggested the Valid Parentheses using the following URL:  https://leetcode.com/problems/valid-parentheses/

The idea is to determine if a sequence of parentheses in a string are properly matched. Please take a look at the actual challenge using the previous URL.

Following is a screen capture of the console on my Eclipse IDE: Continue reading “Valid Parentheses”