Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Tomson Project_Labirynt 1.cpp : Defines the entry point for the console application.
- //
- #include "stdafx.h"
- #include <conio.h>
- #include <iostream>
- using namespace std;
- const int W = 5;
- int segment1[W][W];
- void PoczatkoweWypelnienie()
- {
- int segment1[5][5] = { {0,0,1,0,0},{0,1,1,0,0},{0,1,0,1,1},{0,1,1,1,0},{1,1,0,1,1} };
- }
- void RysowanieSegmentu()
- {
- int a, b;
- for (a = 0; a < 5; a++) {
- for (b = 0; b < 5; b++) {
- if (segment1[a][b] == 0) {
- cout << "#";
- }
- else if (segment1[a][b] == 1) {
- cout << "-";
- }
- }
- cout << endl;
- }
- }
- int main()
- {
- PoczatkoweWypelnienie();
- RysowanieSegmentu();
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement