#How can I include something
25 messages · Page 1 of 1 (latest)
When your question is answered use !solved to mark the question as resolved.
Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.
What's the point
How are you going to create a functional C program without the use of { } characters?
I'd like to know the answer to that as well
To import, you could go and copy paste the file yourself
You might have a few preprocessor conditions to resolve by hand
Could you maybe use a combination of labels + inline assembly + extern functions to create a function?
use compiler flag
;compile -includestdio.h
int main() <: printf("hello"); :>
<source>:1:30: error: expected ']' before ';' token
1 | int main() <: printf("hello"); :>
| ^
| ]
Build failed
this give me:
gcc main.c
main.c:3:5: error: variably modified ‘main’ at file scope
3 | int main() <: printf("hello") :>
| ^~~~
main.c:3:5: error: ‘main’ declared as function returning an array
main.c: In function ‘main’:
main.c:4: error: expected ‘{’ at end of input
why cant you use those characters?
is it a keyboard thing or some bogus challenge?
Refuse to do the challenge because I cannot see how this will be beneficial to you or help you learn anything
you can use Trigraphs i suppose http://port70.net/~nsz/c/c11/n1570.html#5.2.1.1
though its a bit unclear why you'd do it in the first place.
you code above will look like
??=include "/etc/passwd"
int main(void) ??<
return 0;
??>```
Even ? seems to be forbidden
is it? they put their sentence in quotes and those seem to end before the dot (or at least that how i read it)
yeah is it
now it's clearer thanks
yeah is a challenge
@brisk schooner Has your question been resolved? If so, type !solved :)
no
If you can use forbidden symbols inside your compile command you could maybe do stuff like -D BEG={ -D END=} I think that’s how you define stuff