해외취업/면접질문
[해외취업 면접질문①] 자주나오는 인터뷰 질문 5가지 정리!
기록하는 동구
2023. 7. 7. 17:55
반응형
안녕하세요, 동구입니다. 요즘에는 회사들 지원하면서 면접질문들을 뽑아보면서 답변을 공부해보고 있는데요. 같이 공유해서 여러분들도 준비하는데 도움이 됬으면 좋겠습니다.
자자, 질문 리스트 !!!
1. Explain the concept of recursion ( 재귀에대해서 설명해봐)
Recursion is a programming technique where a function calls itself to solve a problem by breaking it down into smaller, simpler instances of the same problem.
By repeatedly applying the recursive case, the problem is eventually solved by reaching the base case.
※ 키워드 : where a function calls itself, breaking it down into smaller, simple instances of the same problem 자기 자신을 부른다는게 있어야함
2. What is the difference between an array and a linked list? ( Array 와 링크드리스트의 차이가 뭐야?)
An array is a contiguous block of memory that stores elements of the same type.
It provides constant-time access to elements based on their index, making it efficient for random access
but less efficient for insertions and deletions. In contrast, a linked list consists of nodes where each node contains a value and a reference to the next node. It does not require contiguous memory and allows efficient insertions and deletions, but accessing elements of performing random access takes linear time
※ 각각에 대한 정의 -> 그로인한 장점 / 단점 (Array는 인덱스이용 -> 일정하게 특정 엘리먼트에 빠르게 접근가능, but 삽입 삭제 느림)
링크드리스트는 다음 노드에대한 정보를 가지고 있기때문에 삽입삭제에 효율적 근데 접근하는게 느림
3. What is the difference between overloading and overriding ? ( overloading 과 overriding 의 차이)
Overloading refers to the ability to define multiple functions with the same name but different parameters within the same class. These functions must have distinct parameter lists, which allows them to be differentiated based on the number, type, or order of arguments. Overriding, on the other hand, occurs when a subclass provides a different implementation of a method that is already defined in its superclass. The overriding method must have the same name, return type, and parameters as the method it overrides.
※ 각각에대한 정의 : 아래 화살을 생각하면 됨
4. Why are different tree traversal methods used in computer science and data structrure ? ( 왜 다른 트리순회 방법들이 있고 쓰이는가 ? )
Different tree traversal methods, such as in-order, pre-order, and post-order traversals, are used to explore and process the nodes of a tree in different orders. These methods have various applications depending on the problem at hand. In-order traversal is commonly used when the goal is to visit nodes in ascending order in a binary search tree. Pre-order and post-order traversals are useful for generating prefix and postfix expressions, respectively. Additionally, tree traversals are essential for tasks like printing the tree structure, evaluating expressions, and constructing tree-based algorithms.
Each traversal method has its own specific use and application. For example:
In-order traversal is useful for printing the nodes of a binary search tree in sorted order or for performing operations that require the nodes to be visited in a specific order.
Pre-order traversal is often used for creating a copy of a tree or when constructing an expression from a binary expression tree.
Post-order traversal is handy when you need to perform some actions on the children of a node before processing the node itself, such as in deleting a tree or evaluating a postfix expression.
참고 : https://yoongrammer.tistory.com/70
5. What is JVM ? Why is Java called the Platform Indexpendant language ?
JVM stands for Java Virtual Machine.
Java's platform independence is achieved through the use of the JVM, which allows Java programs to be executed on any system with a compatible JVM. This feature enables the "Write Once, Run Anywhere" paradigm and provides benefits such as code portability, increased security, and standardized execution.
반응형