Challenge: Proxy Pattern

In this challenge, you have to implement the proxy pattern to solve the given problem.

Problem statement

In this challenge, you have to implement a library kiosk. The LibraryKiosk allows a student to perform two functions:

  • open: allows the student to open an app in the kiosk

  • connectTo: allows the student to connect to a website

The definitions for both the functions are given to you. Currently, using these two functions, the student can open up any app and connect to any website as shown below:

Level up your interview prep. Join Educative to access 70+ hands-on prep courses.