atomic variable c
#include <stdio.h>
#include <stdatomic.h>
int main() {
atomic_int c = ATOMIC_VAR_INIT(0);
// Perform atomic operations on 'c'
atomic_fetch_add(&c, 1);
int currentValue = atomic_load(&c);
// Example of a critical section
// Ensure atomicity when modifying shared data
// ...
return 0;
}