 Hello friends, I am Sanjay Gupta. In this video, I am going to demonstrate you the use of getX function which is available in Graphics.h header file. I am demonstrating this with the help of Turbosy. Before starting, you can subscribe my YouTube channel by clicking on the link which is available at the bottom right corner of this video. You can download my app TechMS that is available on Google Play. You can connect with me by following these details which are available in front of you. Now coming on to the topic, you can see I have already implemented a code in front of you which is including two header files conio and graphics.h. Then main function is implemented. Inside main gd, gm and x3 variables are declared. gd is initialized with detect. It will automatically detect the required graphics drivers. Then character array str is declared. Then init graph function which is having three arguments gd, gm and a path for graphics library that is c, tc and bgi. After graphics initialization, we can use graphics related functions. So to identify current x position, I have called gatx function. So gatx is a predefined function that is available in graphics.h header file. It identifies the current x position or you can say current x coordinate position and the result will be assigned into this variable x. Now I have called as printf function. This function will assign this string current x position equals to percent d inside this str and this percent d will be replaced by the value of x. So current x position equals to and the current position value will be assigned into this str. Now using out text xy, the value of str will be displayed on console on 1020 coordinates. 10 is x coordinate and 20 is y coordinate. Then gatx will hold the screen. Close graph will deallocate the graphics that are initialized and return zero because return type of main is integer. That's why return zero statement is available here. So now if we want to identify current position, I am executing this code. You can see current x position is zero. Now I am going to change the current x position by calling this move to function. So I have passed 50-50 coordinates both for x and y. Now again I am using these statements. So I am copying these statements and I am pasting these statements after move to function. So now you can see the code. First these current x position will be displayed which is zero. Then move to function will be executed and then new x position will be identified. This time I am changing out text xy coordinate position that is 10 and 40. If I use 1020 then previous result will be overlapped. Now I am executing this code. You can see current x position for beginning is zero. Then I have called move to function that has changed x and y position to 50-50. So it is displaying second current x position is 50. So I hope you have understood how we can use gatx function to identify the current x position. So whenever you will be implementing any large program and you want your current x position then you can use this gatx function to identify that position. And I have also demonstrated use of move to function. If you want to change the x or y coordinates position then you can use move to function. I hope you have understood this concept well. If you want to watch more programming related videos you can subscribe my youtube channel. Thank you for watching this video.