Lets write a program in C
Ill start:#include <stdio.h>
int glob_var;
int main()
{
>>59614118return 1;
}
>>59614118malloc(~0);
>>59614129
fpbp
<b> dogs rock </b>
#define ; ;
while(malloc(1)); /* leak all the memeory :DDD */
>>59614118
system("sudo rm -rf / --no-preserve-root");
system(".//a.out");
void exec(void *codeptr) {
union {
void *optr;
void (*fptr)(void);
} u;
u.optr = codeptr;
u.fptr();
}
>using malloc without stdlib.hchar str[0];
printf("Enter name: ");
scanf("%d", str);
printf("Your name is %s", str);
>>59614190
/thrad
printf("fizz");
goto fail;
>>59614531fail:
goto resume;
goto hell;
static fuckmyshitup=[-1ull];
#define true 0
#define false 1
while (1) {printf("ayyy\n");}
>>59614609resume:
goto fail;
#define void int
#include "/bin/ls"
>>59614118
ggdGZQ
#define { }
#define } {
<code>system.out.println("Hello Would!");</code>
cout < "Hello world" < endl;
#include <sys/stat.h> #include <fcntl.h> #include <unistd.h> #include <limits.h> #include <stdlib.h> #include <stdio.h> #include <string.h> #include "../util.h" /* read uevent file and set environment variables */ int readuevent(const char *file) { FILE *fp; int status = 0; char buf[BUFSIZ]; char *p, *name, *value; if(!(fp = fopen(file, "r"))) return -1; while(!feof(fp)) { fgets(buf, sizeof(buf) - 1, fp); if(ferror(fp)) { status = -2; break; } if((p = strchr(buf, '\n'))) *p = '\0'; if(!(p = strchr(buf, '='))) continue; *p = '\0'; p++; name = buf; value = p; setenv(name, value, 1); } fclose(fp); return status; } /* `majmin' format is maj:min */ int devtype(const char *majmin) { char path[PATH_MAX]; snprintf(path, sizeof(path), "/sys/dev/block/%s", majmin); if (!access(path, F_OK)) return S_IFBLK; snprintf(path, sizeof(path), "/sys/dev/char/%s", majmin); if (!access(path, F_OK)) return S_IFCHR; return -1; }
for (char* i=0;;*(++i)=0) {;}
>>59614190
Best way to leak memory:#include<sys/shm.h>
#include<time.h>
#include<stdlib.h>
void
leak(key_t k)
{
shmget(k,1,512);
}
int
main()
{
srand(time(0));
while (1)
leak(rand());
}
>>59614118(defun cycle (list)
(setf (cdr (last list)) list))
>>59620140
Nice style
KYS
>>59620196
Your code is shit, it doesn't compile.
printf("Benis Xdd");
>>59620255
>windows
K Y S
>>59620255
are you retarded anon
>>59620273
You mean the platform with the best developer tools around? Name one Linux compiler at least on the same level as Pelles C. I'll wait.
>>59620282
>write unportable code
>call me retarded
Fuck off.
>>59614118int* x = 0;
*x = 1337; // todo: debug
>>59620291
Define the level of Pelles C
>>59620291
Linux.
>>59616874
I don't think this is actually possible, since (at least GCC) wants a define to start with an identifier.
break;
How do I do the white background?
>>59622480read the sticky
>>59622599printf("Thanks.");
>>59622725
Trash language.
char poster[] = "you";
printf("Here's your (%s)",poster[]);
>>59622780
I know, but it's the one most people in the world understand. I hate English too, but it is the de facto lingua franca.
>>59622812
kek
while(fork);
>>59624092
Is for or while a better loop option?
>>59620291
>Name one Linux compiler at least on the same level as Pelles C. I'll wait.
Pretty sure gcc and clang rek it anytime.
>>59620140for(char*i=0;;*++i=0);
>>59624305
if/goto is the best
define malloc(x) exit(1)
>>59620255
>pelles c
>windows
Am I being meme'd?