Something like that (pseudo code):
कुछ ऐसा (छद्म कोड):