This code from C++ to Turbo C

#include<stdio.h>
#include<conio.h>

public class Stack
{
    private:
        int size;
        int top;
        int *values;
    public:
        Stack(int size)
        {
             this->size =size;
             values = new int [size];
             top = -1;
         }
 void main()
 {
    Stack *myStack = new Stack(10);
 }
};

what will be its output:??
if code is wrong pls. tell me a right code.. thnx...

There is one super easy way to tell what the output is. Compile and run the program.

what will be its output:??

No output. It's not C, and won't compile as C++ either due to syntax errors. But you'd know that if you tried compiling it. :icon_rolleyes:

WHat is this??

C + C# ??

Your code looks like C# and your header declaration looks like C.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.