<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Panchal Aditya Nileshbhai</title>
    <description>The latest articles on DEV Community by Panchal Aditya Nileshbhai (@adityanp1).</description>
    <link>https://dev.to/adityanp1</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1233992%2Faff1aa8b-e95c-44f7-a822-6a04142ec01f.png</url>
      <title>DEV Community: Panchal Aditya Nileshbhai</title>
      <link>https://dev.to/adityanp1</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/adityanp1"/>
    <language>en</language>
    <item>
      <title>C debugger Not able to Print or take Input when in debugger mode is On</title>
      <dc:creator>Panchal Aditya Nileshbhai</dc:creator>
      <pubDate>Thu, 07 Nov 2024 12:29:54 +0000</pubDate>
      <link>https://dev.to/adityanp1/c-debugger-not-able-to-print-or-take-input-when-in-debugger-mode-is-on-703</link>
      <guid>https://dev.to/adityanp1/c-debugger-not-able-to-print-or-take-input-when-in-debugger-mode-is-on-703</guid>
      <description>&lt;p&gt;in .vscode Folder :&lt;/p&gt;

&lt;p&gt;My lanch.json:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    "configurations": [
        {
            "name": "C/C++: gcc.exe build and debug active file",
            "type": "cppdbg",
            "request": "launch",
            "program": "${fileDirname}\\${fileBasenameNoExtension}.exe",
            "args": [],
            "stopAtEntry": false,
            "cwd": "${fileDirname}",
            "environment": [],
            "externalConsole": false,
            "MIMode": "gdb",
            "miDebuggerPath": "C:\\MinGW\\bin\\gdb.exe",
            "setupCommands": [
                {
                    "description": "Enable pretty-printing for gdb",
                    "text": "-enable-pretty-printing",
                    "ignoreFailures": true
                },
                {
                    "description": "Set Disassembly Flavor to Intel",
                    "text": "-gdb-set disassembly-flavor intel",
                    "ignoreFailures": true
                }
            ],
            "preLaunchTask": "C/C++: gcc.exe build active file"
        }
    ],
    "version": "2.0.0"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;task.json :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
{
    "tasks": [
        {
            "type": "cppbuild",
            "label": "C/C++: gcc.exe build active file",
            "command": "C:\\MinGW\\bin\\gcc.exe",
            "args": [
                "-fdiagnostics-color=always",
                "-g",
                "${file}",
                "-o",
                "${fileDirname}\\${fileBasenameNoExtension}.exe"
            ],
            "options": {
                "cwd": "${fileDirname}"
            },
            "problemMatcher": [
                "$gcc"
            ],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "detail": "Task generated by Debugger."
        }
    ],
    "version": "2.0.0"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;c_cpp_properties.json:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
    "configurations": [
        {
            "name": "Win32",
            "includePath": [
                "${workspaceFolder}/**"
            ],
            "defines": [
                "_DEBUG",
                "UNICODE",
                "_UNICODE"
            ],
            "windowsSdkVersion": "10.0.22621.0",
            "cStandard": "c17",
            "cppStandard": "c++17",
            "intelliSenseMode": "gcc-x64",
            "compilerPath": "C:/MinGW/bin/gcc.exe"
        }
    ],
    "version": 4
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsga8cqcljykngmka11td.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsga8cqcljykngmka11td.png" alt="Vs Code Image" width="800" height="425"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;code :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#include &amp;lt;stdio.h&amp;gt;
int main(){
int i;
scanf("%d", &amp;amp;i);
printf("You entered: %d\n", i);
return 0;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Terminal:&lt;/p&gt;

&lt;p&gt;PS C:\Users*&lt;strong&gt;\OneDrive\Documents\INTERVIEW PREP\DSA and Small Learnings&amp;gt;  &amp;amp; 'c:\Users*&lt;/strong&gt;*.vscode\extensions\ms-vscode.cpptools-1.23.0-win32-x64\debugAdapters\bin\WindowsDebugLauncher.exe' '--stdin=Microsoft-MIEngine-In-caznmueg.sx2' '--stdout=Microsoft-MIEngine-Out-kpfaclzx.m3o' '--stderr=Microsoft-MIEngine-Error-nq1rgwan.vxy' '--pid=Microsoft-MIEngine-Pid-d12jsuyv.lf0' '--dbgExe=C:\MinGW\bin\gdb.exe' '--interpreter=mi' &lt;/p&gt;

&lt;p&gt;When I press F5, means i debug my C code, it not prints anything or neither take any inputs if scanf is there, if debugger is at scanf , and if i press F10 , then as shown in picture, Nothing happens. I can Only hover and see the variable value. I have installed&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
 set up,

 ```codeLLB```

 and code runner extensions, as well.

Also, If I not put debugger at scanf function: it waits for input ,but when i write something and hit enter, nothing happens, also the debugger not allow to step next step...And after that if i stop the debugger, then what ever i wrote in terminal ,shows there immediately. Example: if i wrote fffff and then stop debugger then that word executes in terminal!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>vscode</category>
      <category>c</category>
      <category>debugging</category>
    </item>
  </channel>
</rss>
