forked from FarkhodKhuramov/Kartavec-snake
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
kartavec
committed
Sep 13, 2015
1 parent
f0d72dc
commit 71ec7ba
Showing
3 changed files
with
35 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
|
||
namespace Snake | ||
{ | ||
class HorizontalLine | ||
{ | ||
List<Point> pList; | ||
|
||
public HorizontalLine(int xLeft, int xRight, int y, char sym) | ||
{ | ||
pList = new List<Point>(); | ||
for(int x = xLeft; x <= xRight; x++) | ||
{ | ||
Point p = new Point( x, y, sym ); | ||
pList.Add( p ); | ||
} | ||
|
||
} | ||
|
||
public void Drow() | ||
{ | ||
foreach(Point p in pList) | ||
{ | ||
p.Draw(); | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters