+ 5
how can i make tic tac toe (x-o-x) game without using functions in c language?
C
38 Réponses
+ 3
It sounds like your professor is trying to get you all to understand the scope of variables and loops.
You can build a tic tac.toe without a self defined function, you will still have to use main however.
Use a for loop which sets the variable to check for a win
Set your array array of nine to zero
Accept input with all your error checks
Check for win or tie
Break out of loop
+ 8
What do you mean by "functions"? Do you mean, you don't want to write own functions?
May I ask why you don't want to use functions?
+ 3
Have you tried? Let us see your attempt
+ 3
Sololearn has a C course. Maybe youbwoyld like to practice basics ny doing the course and then come back here when you have started your code?
+ 2
Still, what is "without using functions"?
+ 2
I don't know C but know that you clarified your question, others can help you.
+ 2
Muhammet if you go into the Sololearn Code section and search for tic, you'll find about 45 implementations in C to inspire you.
+ 2
C language is easy
+ 1
No function will be used, for example only printf scanf if else switch case while do etc etc these can be used but the function will not be used
+ 1
Yes, I don't know Turkish, sorry. But if you can put your attempt in a code-bit in the sololearn playground we can work on it there.
+ 1
I just downloaded the application, I couldn't find the game part Paul K Sadler
+ 1
Your teacher doesn't want you to use functions because they want to see how you implemented your work. Basically, implement your solution without abstraction.
+ 1
Kusura bakma biraz sert çıkmışım, burası genelde olan bir koda destek vermek için kullanılıyor. Yani kimse sıfırdan kod yazıp eline vermez.
+ 1
C is easy...
Why!!!
If you don't want use C language
Use another like python ....
+ 1
A C program usually at least has the main function as an entry point to the program.
There are certain exceptions though. You can look here on this link
https://stackoverflow.com/q/7050925
I just did a simple Google search btw
+ 1
With your permission, I want to learn programming
0
This is a project assignment, my teacher asked for it.
0
Can you help me?
0
If you have someone you can direct me to, I would appreciate it if you could contact me privately.
0
You could us a while or do while loop taking input while there are still boxes to put x's and o's and no one has won the game. Once no boxes are left or someone has won you would end the loop and the game.