This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// File: glfw_triangle_white.c | |
// Date: 2024-07-11 | 2024-07-11 | |
#include <GL/gl.h> | |
#include <GLFW/glfw3.h> | |
#include <stdio.h> | |
#define WINDOW_WIDTH 800 | |
#define WINDOW_HEIGHT 600 | |
#define WINDOW_TITLE "Triangle" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// File: `glfw_window.cpp` | |
// Date: `2024-07-03` | |
#include <GLFW/glfw3.h> | |
#include <GL/glut.h> | |
int main() | |
{ | |
// Initializing glfw | |
glfwInit(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************************** | |
* File: ford_car.c | |
* Date: 2024-06-11 | 2024-06-11 | |
**************************************/ | |
#include <stdio.h> | |
#define FORD_BRAND "Ford" | |
#define FORD_CAR_MODEL "F3310" | |
#define FORD_CAR_F3310_YEAR 2024 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*************************************************************** | |
* File: physic.h | |
* Date: 2024-05-31 | 2024-06-01 | |
***************************************************************/ | |
#ifndef PHYSIC_H | |
#define PHYSIC_H | |
#include <math.h> // Library to `sqrt` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*************************************************************************** | |
* File: sdl2_window_blank.c | |
* Date: 2024-05-31 | 2024-06-06 | |
***************************************************************************/ | |
#include <SDL2/SDL.h> | |
#include <stdbool.h> | |
#define WINDOW_SIZE_X 800 // Window width. | |
#define WINDOW_SIZE_Y 600 // Window height. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/****************************************** | |
* File: hello_world.c | |
* Date: 2024-05-20 | 2024-05-31 | |
******************************************/ | |
#include <stdio.h> // The standard library to `Hello, world!` can be printed on console. | |
// Function that the compiler will search first for. | |
int main(int argc, char const *argv[]) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// File: bad_malloc.c | |
// Date: 2024-05-21 | 2024-07-03 | |
#include <stdlib.h> // Library to malloc | |
#include <stdbool.h> // Library to bool | |
int main() | |
{ | |
while(true) // Loop to create the garbage. | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// hello_world.cpp | |
#include <iostream> | |
int main(int argc, char const *argv[]) | |
{ | |
std::cout << "Hello, world!\n"; | |
return 0; | |
} |