Linguagem C - Aula 1.1 - Aprenda a usar o DEV C++ (2022)

3 min read 2 months ago
Published on Aug 25, 2024 This response is partially generated with the help of AI. It may contain inaccuracies.

Table of Contents

Introduction

This tutorial is designed to help you get started with the C programming language using the DEV C++ IDE. Whether you're a beginner or refreshing your skills, this guide will walk you through the installation and initial setup of DEV C++, along with some fundamental concepts of C programming.

Step 1: Download and Install DEV C++

  • Visit the official DEV C++ website or a trusted software repository.
  • Look for the download link for the latest version of DEV C++.
  • Download the installer file to your computer.
  • Once the download is complete, locate the installer and double-click it to start the installation process.
  • Follow the on-screen instructions:
    • Accept the license agreement.
    • Choose the installation directory (default is usually fine).
    • Complete the installation.

Step 2: Set Up DEV C++

  • Open DEV C++ after installation.
  • Configure the IDE settings to your preference:
    • Go to Tools > Editor Options to customize text size, colors, and other preferences.
    • Under Tools > Compiler Options, ensure that the correct compiler settings are selected for C programming.

Step 3: Create a New Project

  • Click on File > New > Project.
  • Select Console Application from the project options.
  • Choose C as the programming language.
  • Name your project and select a location to save it.
  • Click OK to create the project.

Step 4: Write Your First C Program

  • In the project window, right-click on the source file (usually named main.c) and select Open.
  • Start typing your C code. Here’s a simple program to display "Hello, World!" on the screen:
#include <stdio.h>

int main() {
    printf("Hello, World!\n");
    return 0;
}

Step 5: Compile and Run Your Program

  • Save your changes by clicking File > Save.
  • Compile your program by clicking on the Execute menu and selecting Compile & Run (or simply press F9).
  • Check the output window for the result. You should see "Hello, World!" displayed.

Step 6: Explore Further Learning Resources

  • Consider checking out exercise lists and slides available through the instructor’s platform for additional practice.
  • If you encounter difficulties in programming concepts, consider scheduling a private lesson for more personalized guidance.

Conclusion

You have successfully set up DEV C++ and written your first C program. By following these steps, you can continue to explore more advanced programming concepts and practice your skills. For additional resources or support, don't hesitate to reach out to your instructor through the provided contact options. Happy coding!