</>
CodeWithZohaib
Toggle theme
Connect
Add
Ruby Programming Guide
All Topics
Basic Concepts (1-20)
Advanced Topics (21-40)
Pointers & Memory
Structures & Unions
File Handling
1. What is Ruby?
2. What is a variable in Ruby?
3. Explain if-else statement.
4. What is a loop?
5. What is an array?
6. What is a hash?
7. Explain the for loop syntax.
8. How to define a function in Ruby?
9. Explain the while loop.
10. What is a class in Ruby?
11. Explain inheritance in Ruby.
12. What is a module?
13. Explain method overriding.
14. What are blocks in Ruby?
15. What is a Proc?
16. Explain lambdas.
17. What is self in Ruby?
18. What are instance variables?
19. What is a singleton method?
20. Explain string interpolation.
21. Explain encapsulation.
22. What is a ternary operator?
23. What is an enumerator?
24. Explain symbols in Ruby.
25. What is a range?
26. Explain attr_accessor.
27. What is exception handling?
28. Explain yield keyword.
29. What is monkey patching?
30. Explain duck typing.
31. What is metaprogramming?
32. What are Ruby Gems?
33. Explain mixins and how they work in Ruby.
34. What are Ruby blocks, and how do they work?
35. Explain the concept of aliasing methods in Ruby.
36. What is a singleton class?
37. Explain method_missing and its purpose.
38. What is a constant in Ruby?
39. Explain the difference between public, private, and protected methods.
40. What is introspection in Ruby?