Add office photos
Premium Employer

NEC

4.4
based on 1.4k Reviews
Filter interviews by

Hotel Green Leaf Interview Questions and Answers

Updated 5 Feb 2024

Q1. Round 2: capitalize 1st and last character of each word in a given string. Eg: 'hello there' should return 'HellO TherE'

Ans.

The task is to capitalize the first and last character of each word in a given string.

  • Split the string into an array of words

  • Iterate through each word and capitalize the first and last character

  • Join the modified words back into a string

View 2 more answers

Q2. Round 1 : What is the difference between list and a tuple?

Ans.

List is mutable while tuple is immutable.

  • List can be modified while tuple cannot be modified.

  • List is defined using square brackets [] while tuple is defined using parentheses ().

  • List is used for homogenous data while tuple is used for heterogenous data.

  • List is slower than tuple in terms of performance.

  • Example of list: [1, 2, 3] and example of tuple: (1, 'hello', 3.14)

Add your answer

Q3. Round -2 : reverse a string using recursion.

Ans.

Reverse a string using recursion.

  • Create a function that takes a string as input.

  • Check if the string is empty or has only one character.

  • If yes, return the string.

  • If not, call the function recursively with the substring excluding the first character and concatenate the first character at the end.

  • Return the reversed string.

View 1 answer

Q4. Explain the rj45 connector with its colour specifications

Ans.

The RJ45 connector is a standardized physical interface for connecting ethernet cables, with color specifications for wiring.

  • RJ45 connectors have 8 pins and are commonly used for Ethernet connections

  • The color specifications for wiring in an RJ45 connector are typically T568A or T568B standards

  • T568A wiring uses green and orange pairs, while T568B uses orange and green pairs

  • For example, in T568B standard, pin 1 is white/orange, pin 2 is orange, pin 3 is white/green, pin 6 is gr...read more

Add your answer
Discover Hotel Green Leaf interview dos and don'ts from real experiences

Q5. Give example of how cloud works

Ans.

Cloud computing allows users to access and store data and applications over the internet instead of on a physical hard drive.

  • Data and applications are stored on remote servers and accessed through the internet.

  • Users can access their data and applications from any device with an internet connection.

  • Cloud services can include storage, databases, networking, analytics, and more.

  • Examples of cloud services include Amazon Web Services (AWS), Microsoft Azure, and Google Cloud Platfo...read more

Add your answer

Q6. Round 1: What is generator?

Ans.

A generator is a device that converts mechanical energy into electrical energy.

  • Generators are commonly used in power plants to produce electricity.

  • They work on the principle of electromagnetic induction.

  • The mechanical energy can be provided by various sources such as steam turbines, gas turbines, wind turbines, etc.

  • Generators can be classified into AC generators and DC generators.

  • AC generators are used in most power plants while DC generators are used in some specific applica...read more

Add your answer

Q7. Round 1: What is a decorator?

Ans.

A decorator is a design pattern in object-oriented programming that allows behavior to be added to an individual object, dynamically.

  • Decorators are used to modify the behavior of a function or class without changing its source code.

  • They are implemented using the @ symbol in Python.

  • Decorators can be used for logging, timing, caching, and more.

  • An example of a decorator is the @staticmethod decorator in Python, which marks a method as static.

  • Another example is the @property deco...read more

Add your answer

Q8. Round 1: What is .pyc file?

Ans.

A .pyc file is a compiled Python file that contains bytecode.

  • It is created by the Python interpreter when a .py file is imported or run.

  • It is platform-independent and can be executed on any system with the same version of Python.

  • It speeds up the execution of Python code as the interpreter does not have to compile the code every time it is run.

  • It can be deleted without affecting the original .py file, as the interpreter will re-create it if necessary.

Add your answer

Q9. Aws cloud vs azure vs gcp

Ans.

AWS, Azure, and GCP are three major cloud service providers offering a range of services and features for businesses.

  • AWS (Amazon Web Services) is the oldest and most widely used cloud platform, offering a wide range of services and global data centers.

  • Azure (Microsoft Azure) is known for its strong integration with Microsoft products and services, as well as its hybrid cloud capabilities.

  • GCP (Google Cloud Platform) is known for its strong data analytics and machine learning c...read more

Add your answer
Contribute & help others!
Write a review
Share interview
Contribute salary
Add office photos
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Graduate Engineer Trainee (Get) Interview Questions from Similar Companies

3.9
 • 48 Interview Questions
3.6
 • 25 Interview Questions
3.5
 • 20 Interview Questions
4.1
 • 11 Interview Questions
3.9
 • 10 Interview Questions
4.2
 • 10 Interview Questions
View all
Share an Interview
Stay ahead in your career. Get AmbitionBox app
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
70 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions
Get AmbitionBox app

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter