Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprenda Challenge: Overloaded Movie Class | Constructors and Overloading
C# OOP Class Construction Drills

bookChallenge: Overloaded Movie Class

Tarefa

Swipe to start coding

Create a Movie class that supports multiple ways to initialize its fields using overloaded constructors.

  • The class must have a default constructor that sets the Title to "Unknown" and ReleaseYear to 0.
  • The class must have a constructor that takes a title parameter and sets Title to the given value and ReleaseYear to 0.
  • The class must have a constructor that takes both a title and a releaseYear, and sets the fields accordingly.

Solução

Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 1. Capítulo 4
single

single

Pergunte à IA

expand

Pergunte à IA

ChatGPT

Pergunte o que quiser ou experimente uma das perguntas sugeridas para iniciar nosso bate-papo

Suggested prompts:

Can you explain this in simpler terms?

What are the main takeaways from this?

Can you give me an example?

close

bookChallenge: Overloaded Movie Class

Deslize para mostrar o menu

Tarefa

Swipe to start coding

Create a Movie class that supports multiple ways to initialize its fields using overloaded constructors.

  • The class must have a default constructor that sets the Title to "Unknown" and ReleaseYear to 0.
  • The class must have a constructor that takes a title parameter and sets Title to the given value and ReleaseYear to 0.
  • The class must have a constructor that takes both a title and a releaseYear, and sets the fields accordingly.

Solução

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 1. Capítulo 4
single

single

some-alt