TypeScript

0.0(0)
studied byStudied by 3 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/3

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

4 Terms

1
New cards
implements the interface?
implements the interface?
\n You can use implements to check if a class meets a specific interface. \n Failure to implement the class correctly will result in an error. \n The implements clause is to ensure that a class can be treated as an interface type. It doesn't change the class's types or methods at all. \n A class can also implement multiple interfaces. Class C implements A and B. \n ex) class C implements A, B { } \n \`\`\` \n interface Pingable { \n ping(): void; \n } \n \n // Since the Sonar class implements the Pingable interface, the ping method of Pingable must be implemented. \n class Sonar implements Pingable { \n ping() { \n console.log("ping!"); \n }
2
New cards
polymorphism in OOP?

polymorphism in OOP
\
Polymorphism in OOP allows objects to have multiple forms or behaviors. This means different class objects can be treated as if they are the same class, making code more flexible. It can be achieved through method overriding or method overloading.
3
New cards
s
s
4
New cards
ss
s