Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions HelloStudents/HelloStudents.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Student3099Ham.cs" />
<Compile Include="Student3108Kim.cs" />
<Compile Include="Student3103Kim.cs" />
<Compile Include="Student3199Ham.cs" />
<Compile Include="StudentBase.cs" />
Expand Down
12 changes: 11 additions & 1 deletion HelloStudents/Program.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
using System;
// using은 java의 import 같은 역할
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

// namespace는 java의 패키지 같은 역할
namespace HelloStudents
{
class Program
Expand Down Expand Up @@ -48,6 +50,14 @@ static void Main(string[] args)
// 3106
// 3107
// 3108
students.Add(
new Student3108Kim()
{
FirstName = "지영",
LastName = "김",
StudentNumber = 3108,
BaseYear = 2021
});
// 3109
// 3110
// 3111
Expand Down
17 changes: 17 additions & 0 deletions HelloStudents/Student3108Kim.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HelloStudents
{
class Student3108Kim : StudentBase
{
public override string Hello()
{
return "안녕? 나는 " + this + "이야!";
// return "안녕? 나는 " + this.ToString() + "이야!";
}
}
}