xxxxxxxxxx
flask db init
flask db migrate -m 'Create message for what you did'
flask db upgrade
xxxxxxxxxx
/* These are preprocessor directives in C. They might sound like quite a mouthful,
but they're simply instructions that tell the compiler to include libraries.
These libraries contain a set of pre-written functions and tools, making it easier
to perform various tasks without reinventing the wheel. */
#include <stdio.h> // Library for standard input/output operations
#include <stdlib.h> // Library for memory management and general utilities
// It is preprocessor directives that allow access to these sets of functions
int main(void) {
printf("Hello, World!\n"); // printf is imported from stdio
// Allocate memory for an array of 10 integers using malloc from stdlib
int *var = malloc(10 * sizeof(int)); // malloc is imported from stdlib
// Check if malloc was successful
if (var == NULL) {
printf("Memory allocation failed!\n");
return 1; // Exit the program if memory allocation fails
}
// Assign values to the allocated memory
for(int i = 0; i < 10; i++) {
var[i] = i;
}
// Print values stored in allocated memory
for(int i = 0; i < 10; i++) {
printf("%d ", var[i]);
}
printf("\n"); // Newline for cleaner output
// Free the allocated memory to prevent memory leaks
free(var);
return 0; // Indicate successful program completion
}