It was out of fear for this day that browser developers didn't allow the remote execution of C code.
@andrewporter18682 жыл бұрын
...so they made an architecture called WebASM that C can compile to.
@_Channel_Deleted_2 жыл бұрын
@@andrewporter1868 Yes
@SIGMA_BLYAT2 жыл бұрын
u use vim u alredy have no respect from react komunity
@TheOwlTheOne2 жыл бұрын
Hello channel deleted, i’m deleted too😅
@QuickBitMastery2 жыл бұрын
@@andrewporter1868 XD
@blablabla77962 жыл бұрын
Lvl 0 programmer: oh X is the best programming language because of reasons A, B, C Lvl 1 programmer: you should use the best tool for each job and not be dogmatic about any particular programming language Lvl 10 programmer: write it in C anyway lulz
@imraninfrarote2 жыл бұрын
Lvl 69: Use python for work Use C and shit on python on yt
@alefratat40182 жыл бұрын
I mean, everything I program is in C because I did not bother to learn another language and have other things to do in my life. Nice to hear that it makes me a lvl 10 programmer in your view though, haha.
@blablabla77962 жыл бұрын
@@alefratat4018 that makes you level 0 though.
@wrong10292 жыл бұрын
@@alefratat4018 you act like it takes a REALLY long time to learn a new language. That's definitely not the case, especially if you know c.
@jg2kpy2 жыл бұрын
@@imraninfrarote pñ
@JamesNewton2 жыл бұрын
This is an excellent educational project. The code is clean and easy to understand. I probably wouldn't actually use it in production, cuz there's no checking for overruns, Etc. But as a way to learn what's actually involved in a web server I haven't seen a better example. I especially liked the binary search/ map
@imraninfrarote2 жыл бұрын
Well, obviously it is not anywhere near ready for being used in production. I just wanted to make this because it's a cool project and I learned a lot from it. I'm still learning and trying to improve on it. Thanks a lot for your support. It really means a lot
@spicy80472 жыл бұрын
@ThatGuyJamal for me, rusts "the book" is a wonderful introduction. Rust as in the language
@sa1t9382 жыл бұрын
@ThatGuyJamal i have been learning rust recently and I have to say that openAI's chatGPT AI is really good at answering programming questions. I can copy paste errors I don't understand there and it will tell me what exactly it means, or I can ask it how to do something and it will provide a code snippet. Honestly has made learning like 5x easier.
@wlockuz44672 жыл бұрын
LGTM!
@ygypt2 жыл бұрын
what is overrunss and why are they bad?
@billy84612 жыл бұрын
That was the first exercise for the course operating systems in my Uni. We built a multithreaded server from scratch in c, utilizing pthreads, signals, sockets, mutual exclusion for the db, and synchronization of the incoming requests using a FIFO queue. One of the best projects actually!
@imraninfrarote2 жыл бұрын
It's really such an interesting topic to dive into. I mean all the stuff that we (web developers) take for granted, it's just mind boggling.
@bryanherreradev80552 жыл бұрын
tell me where you went to college, at mine we didn't go beyond a simple cashier system. xD
@billy84612 жыл бұрын
@@bryanherreradev8055 I studied computer science and engineering at the university of Ioannina, Greece.
@ahmedalhallag33382 жыл бұрын
Can you mention the recourses/essential-readings and any other kind of useful materials that were listed in your course descriptor of this module?
@GamerSenior2 жыл бұрын
Would love to take a read at those materials too if you still have it
@brumarul7481 Жыл бұрын
I remember watching this vid 1 year ago, beeing like, who tf would do that in c.... Year 2 in uni, implement an async server in c.... I hate my life..
@AifakhYormum9 күн бұрын
let me guess... automatica?
@addowhite63312 жыл бұрын
For anyone looking to do this in production (I reduced my AWS bill by switching from Python to C/GO), I can recommend Ulfius or libonion
@maratmkhitaryan97232 жыл бұрын
What was there? Web app or just serving static?
@orubenlopes2 жыл бұрын
By how much (percentage is fine) have you reduced your AWS bill and could you share with us what is your application like at a high level?
@peq42_2 жыл бұрын
For anyone looking to do this in production, I recommend therapy
@zweitekonto96542 жыл бұрын
@@peq42_ Is that library? Or pun intended.
@dolevgo85352 жыл бұрын
@@peq42_ based
@bakedgiraffe2 жыл бұрын
My man using C and Vim? Absolute god-tier programmer. I aspire to be as based as this one day
@biomorphic2 жыл бұрын
Good programmers choose the right tool for the job. Good programmers use an IDE, because they do understand the importance of using a debugger, so they can check the value of a variable without having to log it to the console, use watches, change values on the fly, debug step by step. Noobs use vim because they think it's cool and they believe programming is about how fast you can write the code because you can keep your hands on the keyboard. Also C in 2022 is a bad choice for anything, included low level programming, where C++ and Rust and Zig are a much better choice. Just a free advice from someone with 25 years of experience in the industry.
@bakedgiraffe2 жыл бұрын
@@biomorphic cope
@jongeorge33582 жыл бұрын
@@biomorphic Ever heard of GDB? real men only use the terminal
@IFrozenFireI2 жыл бұрын
@@biomorphic As an ex-dev in over 3 FAANG & FORTUNE 50 companies, I absolutely agree.
@miles21422 жыл бұрын
@@biomorphic I'd just say to use emacs or vscode with vim keybinds
@LalanDesai2 жыл бұрын
This guy sleeps on the warm side of his pillow.
@imraninfrarote2 жыл бұрын
How could you tell?
@patrickdavis92092 жыл бұрын
We actually had this as an assignment in our computer science course at uni and I found it a great learning experience for both C and HTTP/IP
@imraninfrarote2 жыл бұрын
I'm not sure if our networking course has this project/assignment. But it would be cool to have this
@pulgamecanica2 жыл бұрын
Same
@rakeshchowdhury2022 жыл бұрын
@@imraninfrarote in us uni they have networking and db. Indian syllabus has only algorithms and basics. I'm guessing you're Indian from geeksfromgeeks page.
@patrickdavis92092 жыл бұрын
COMP30023 "Computer Systems" at the University of Melbourne for anyone wondering
@imraninfrarote2 жыл бұрын
I'm actually Bangladeshi
@ColdFuse962 жыл бұрын
I freaking love that coding kind of imbues us with this chaotic energy that makes us do *whatever* because we can 😂😂😂
@aslkjfdasfkjdaskljfajklsfa2 жыл бұрын
Writing an multi threaded web server using only std is literally the main example in the Rust book 💀💀💀
@fuzzy-023 ай бұрын
Ahhh C. It is like drinking coffee and relaxing after lunch. Wether the cup contains little coffee and sugar, or half a ton of coffee is another thing
@jaywilzon14122 жыл бұрын
The cool thing will be to get to a point where you can run a performance benchmark against stuff like apache iis and node express. Or even that new rust framework leptos
@imraninfrarote2 жыл бұрын
That's actually on my todo list. But for now, I'm just trying to get the basics done
@gianni507252 жыл бұрын
until you get near feature parity, benchmarks aren't very useful, so that will be a long while off
@wrong10292 жыл бұрын
leptos is a full stack framework. axum would be a more apt comparison.
@snapshot272 жыл бұрын
The project is interesting, I did the same for a tp at the university. Once you do one of these you really understand how the web works
@imraninfrarote2 жыл бұрын
That's one of the main reasons I wanted to make this in the first place
@n2cotine2 жыл бұрын
Only 121 subs ? I thought this was already a big tech channel 😮 Keep going !
@blu3r4d0n2 жыл бұрын
same
@imraninfrarote2 жыл бұрын
Appreciate the support mate
@vaisakh_km2 жыл бұрын
😶 okk you got a sub
@billowen32852 жыл бұрын
484 now lol
@secretsorcerer2 жыл бұрын
@@billowen3285 696 now
@omar_benaidy2 жыл бұрын
you know this guy is the real deal when he uses geeks for geeks
@SpencerYonce2 жыл бұрын
Bro this was awesome. I would absolutely love to see more of these web servers in C series. Also, you have inspired me to try this myself :)
@koushikmahavadhi8901 Жыл бұрын
Bro could you explain how to run this project
@dimiutube2 жыл бұрын
Pretty nice 🙂It remembers me the old days where we had to create lots of programs using C and C++ and we didn't have a nice editor with all the syntax highlighting and code completion... *sigh* But it was a lot of fun 🙂
@woosix77352 жыл бұрын
Now we get to create programs in c but with syntax highlighting and code completion !
@tristanmisja2 жыл бұрын
As someone who has also done this, I can say it was pretty darn fun.
@rdubb772 жыл бұрын
The C language is one of the most important human developments of the last 50 years.
@rothbardfreedom2 жыл бұрын
Next logical step: Assembly
@imraninfrarote2 жыл бұрын
Don't post spoilers pls
@rothbardfreedom2 жыл бұрын
@@imraninfrarote If POST os prohibited, it should return a 403 not a 200.
@NicChap2 жыл бұрын
Love the humour. I have done large projects using the Websockets API ... fun fun fun!
@bvg1292 жыл бұрын
I left a like and a comment to promote this video. Good stuff, keep it up, add more details
@imraninfrarote2 жыл бұрын
Thanks a lot 😊 Really appreciate the support
@sywker2 жыл бұрын
If I had to implement route mapping I would suggest using a Trie. It is simpler than a balanced BST, has better time complexity and extending it to support common features like catch all routes (/catch-all/*) and slugs (/products/:slug:/p) is very straightforward.
@imraninfrarote2 жыл бұрын
Interesting. I was actually wondering how I'd handle slugs and stuff. I'll definitely take a look at it. Thanks for suggesting
@AjaySharma-vz9ei2 жыл бұрын
i worked as a software developer in Embedos Engineering in Mumbai India, here we use to make IOT edge devices with SBC's and Microcontrollers. We used Esp32 and wrote our own code in C from scratch created web servers to achieve 2 way communication between the device and the end user for device configuration and data visualization, can connect to the device once in the same network just get the IP of esp32 it serves html files stored in it (esp32).
@GyanPrakash-xo5gs2 жыл бұрын
This is such a good video, I see your channels gonna explode with content. You won my sub.
@glitchy_weasel2 жыл бұрын
What a nice neat little project. The code is easier to understand than I thought.
@RomainRyko2 жыл бұрын
I loved the video, I'm still a newbie in C but I'll definitely try something like this !
@imraninfrarote2 жыл бұрын
In my experience, the best way to learn a programming language (or programming in general) is to simply build stuff with it. It doesn't have to be the next big thing. When I started coding I went nuts and built tons of questionable programs.
@nerdastics39872 жыл бұрын
Don’t until you really know what you’re doing
@chocolate_maned_wolf2 жыл бұрын
rip 💀💀
@eitansegev2 жыл бұрын
bro so pro making the impossible possible in 3 minutes
@basedjunayed_2 жыл бұрын
Really liked your video. You earned a new subscriber. শুভকামনা রইলো
@imraninfrarote2 жыл бұрын
Really appreciate it. ধন্যবাদ।
@tofoo_ninja2 жыл бұрын
Nice project Dude! Good luck and have fun 😊
@youdontsay25292 жыл бұрын
This is some sort of artistic endeavor.
@sandiguha8 ай бұрын
good job brother. this motivated me to write same in python or c++
@rubencoetzer41692 жыл бұрын
nice work, C is fast, scary fast, emphasis on the scary especially in Prod
@imraninfrarote2 жыл бұрын
Forget prod. The development part itself is a nightmare
@yapdog2 жыл бұрын
@@imraninfrarote A nightmare? Nah. I've been programming in C for 3 decades, and I prefer it. So do the developers of virtually every other systems developer.
@imraninfrarote2 жыл бұрын
@@yapdog well, I clearly don't have experience like you do. So a huge portion of the time, I'm not even sure what I'm looking for. I will strive to be efficient in systems programming as it is something that truly interests me
@yapdog2 жыл бұрын
@@imraninfrarote Coolness 😎 I'll try to keep up on your progress, but I'm sure I'm sure I'll learn a thing or three along the way. You're never too old to learn something new, right?
@jacobdurgin46622 жыл бұрын
Wonderful work, I appreciate your humility. I'm excited to see where it goes!
@mechantl0up2 жыл бұрын
We had to build a web server in C for a network programming project at university. This was in 2005.
@wesleychaffin40292 жыл бұрын
One option for the routing map would be a trie structure, might be a bit better than a bst
@lucasa87102 жыл бұрын
dude the "0 hours and 69 minutes" really got me LMAO
@white-bunny2 жыл бұрын
Great Video! Well if you want to try this again, but with an easier to use API, C has GLib+GIO (spun off from the GTK project) which you can use to write all of this in Pure C. GLib can provide pre-built data structures (yes, it has Hash Maps), and GIO which provide a high level File and Socket API including streams, all in Pure C. (Note, GLib and GIO DOES NOT depend on GTK, you can import them independently).
@MxSlfDstrct2 жыл бұрын
honestly I feel like 50% of C's problems would be solved if arrays just knew their own fucking length
@Mustafa-0992 жыл бұрын
LOL! The rick roll really got me!! xD Awesome content homie!
@QuickBitMastery2 жыл бұрын
This isn't just a learning project. As a backend developer (who loves C/C++ More than any other language) i am about to write my own web server using C++ (i use C++ instead of C just for tge OOP i don't use the STL i hate it) That's because most used web servers are open source and available for everyone, so hackers can download and start pentesting the webserver, potentially detecting an RCE vulnerablitity which puts all servers using this web server at risk. When we write our own PERSONAL web server, we'll avoid all types of server attacks (because our web server isn't available for hackers to pentest) and pentesting requires debugging, analyzing the source code, and so on.... This video is like a push to me to create my own web server that serves files, and execute backend scripts such as python, php, and javascript.
@absalomdraconis2 жыл бұрын
The reduction in penetration testing stops being so valuable when the server is running scripts, because of the increased chance of unsafe inputs slipping into the interpretter.
@QuickBitMastery2 жыл бұрын
@@absalomdraconis 100%, That's Why Im Going to mirror user input through multiple input validation bridges inside the server itself before throwing it to the interpreter.
@Ovicron2 жыл бұрын
> i don't use the STL i hate it lol..
@levyroth2 жыл бұрын
Security through obscurity is not security.
@QuickBitMastery2 жыл бұрын
@@levyroth why bro
@disheveledviewer61932 жыл бұрын
Now that AI can write code, *everything* should be written in C
@autistadolinux53362 жыл бұрын
If we were in the old days, we wouldn't be using C as you did but instead through a superserver, like inetd, and you could easily make a server using printf's, read() and write() to stdin/stdout (you could make a webserver with AWK or Shell script like this). Second, if you are already using unix sockets, you can use unix/posix functions, and there's regex in posix c. Fun fact: Even the UNIX "fathers" didn't like sockets (that came from BSD, not UNIX) but their solution was only done in Plan 9 through the /net directory, and they had to reinvent how file system works to make it work (and in the process they created private namespaces, which somehow creeped to linux as mount namespaces, and in linux the mount namespace is as powerful as private namespace of Plan 9, but everyone uses as only a gimick for isolating environments like chroots. This is sad, to be honest...)
@spaghettiking6538 ай бұрын
So you're suggesting you can do communication across the network via mounting?
@autistadolinux53368 ай бұрын
@@spaghettiking653 on plan 9 yes, but only because plan 9 treat fs differently. all fs in plan 9 works like FUSE on linux/macos.
@premiumshiptosts22632 жыл бұрын
Jesus Christ, not only is he writing C code in VIM but he is also using Linux, not any Linux distro, but an RPM based distro. 👏🏾👏🏾👏🏾 a fellow man of culture, Based.
@mek101whatif72 жыл бұрын
Your data is gonna race faster than Bolt
@eugenem5292 жыл бұрын
In-depth tutorial is much appreciated. Like
@KeyboardKrieger2 жыл бұрын
This video remembered me, why I prefer using c# instead of its ancestors 😁
@KeyboardKrieger2 жыл бұрын
@Peter Brown for sure. Being fast is important in many fields. But I'm just to lazy to fight with all the struggle which is the cost for speed
@MyWatermelonz2 жыл бұрын
The beej network guide is great for this if anyone wants to try or learn it. It's a good overall guide for new people. Now just need to learn parallel/concurrent programming...
@KirillTitov2 жыл бұрын
have fun migrating it all to epoll, see you next autumn
@Satyam1010-N2 жыл бұрын
When he said python garbage , my context manger got pissed .
@jameshertz24612 жыл бұрын
That was a great idea. I will try to it on my own as well.
@maverickreal092 жыл бұрын
The most intense coffee you'll never need.
@Mystery12 жыл бұрын
Here before 1mil views. Good job man!
@НейроАстральнаяСова2 жыл бұрын
Really fun video, mate! I am subscribing! Liked how you forget to regord once and at the begining as you said that you didn't copy the code from the YT tutorial 😂😂
@bokajira2 жыл бұрын
Nice style kinda like liveoverflow.
@thearturs2 жыл бұрын
Looking forward to seeing some benchmarks!
@iamworstgamer2 жыл бұрын
freshers: we use chatgpt experienced: we u se documentation legends: I code in c
@CodeWithBehram74972 жыл бұрын
Really So much impressed brother and i myself like C Language and want to make my FYP project in C. The C Language is best for beginners that wants to learn programing. Actually from C or C++ you understand and learn alot of basic concepts of programing which i think most of the programers still dont understand clearly and that is the reason for their poor cpde quality. Looking forward for more informative videos from you :)
@pedrogabrielnogueira10682 жыл бұрын
Amazing video. You rickrolled me. +Respect
@devhashira Жыл бұрын
0 hours and 69 minutes, bro broke math
@SameAsAnyOtherStranger2 жыл бұрын
Ima let my dog know he had a whole week of spending afternoons at the dog park because I used gRPC. Thank you from him in advance.
@vicradon2 жыл бұрын
Zero hours and 69 minutes 😂 This has to be a memory overflow
@whitedevil-bc1ht2 жыл бұрын
A cool project but I enjoy having a good mental health
@mrcrackerist2 жыл бұрын
Basically my day job sockets, epoll, clone and so on.
@BusinessWolf12 жыл бұрын
I was actually researching this topic at one point. Glad to see I'm not the only one who should be put in an institution.
@hnmcclain2 жыл бұрын
My man!!!!! Love seeing my younger bros understand the power and perfection of K-n-R!!!!!
@rovolution82482 жыл бұрын
Part 2 - Building my own Javascript framework
@imraninfrarote2 жыл бұрын
Not a bad idea though. It'll be an absolute blast to dive that deep into the JS world
@eduardabramovich12168 ай бұрын
I wish you actually made a full tutorial on how to do this.
@lukaskreuzer64052 жыл бұрын
42 Students hate this trick
@martingeorgiev999 Жыл бұрын
1:55 ordered maps are most often B-trees for cache efficiency
@linuxkerem2 жыл бұрын
So out of context but finally a user of fedora which is a developer, love it
@imraninfrarote2 жыл бұрын
Honestly I'm really loving fedora
@SomeSubhuman2 жыл бұрын
based
@RadojeFrom2 жыл бұрын
back in the uni, my prof said only an idiot will use C to develop a web server. And that what I also did. I am so glad that I am not the only idiot in this world :D
@ChrisNyaga2 жыл бұрын
It's like his writing dna codes.
@axintruong62322 жыл бұрын
When the "C" character come out in intro screen. I thought the next character is "#" :)))) crazy.
@valdompinga2 жыл бұрын
"It ain't that much" Brah, that's C!
@Zdshh122 жыл бұрын
According to the legend, gods only programming in vim.
@dr4kk0nnysinc592 жыл бұрын
Great video lmao Do a tutorial in this kind of style on how to use vim
@luky420lmao82 жыл бұрын
that's awesome dude, keep at it!
@spencerwilson-softwaredeve63842 жыл бұрын
Would be a great programming assignment for a university course
@nitsanbh2 жыл бұрын
The memes level in this video is superb, 11/10
@tear7282 жыл бұрын
But can you do it in FORTRAN?
@MundodasGuitarras7 ай бұрын
I really wonder if anything can be done in any language. Like...can you do a website with cobol? Or a rest API with assembly, etc
@markus49252 жыл бұрын
That’s really cool, man 👍
@abrarmasumabir38092 жыл бұрын
Bhai that was awesome!
@pranavbedekar58442 жыл бұрын
hey can a program be made in c language that gets input question from user , uploads it on google and then pastes the answer from google as output?
@rsflipflopsn2 жыл бұрын
bro this is like truely entertaining, +1
@MixDei11 ай бұрын
I’d like to spread rendering pages from js interpreter so may be possible to use only c as principal language to create web pages
@aelinwhitehorn35262 жыл бұрын
The hero we need but do not deserve
@imraninfrarote2 жыл бұрын
Hey. I'm just messing around and trying to build cool stuff. I'm no hero, just a regular dude
@ExKernel.A.M.2 жыл бұрын
@@imraninfrarote that's what a real hero would say...
@Infi9tea2 жыл бұрын
I started my c journey and its interesting to watch as a newbie
@fantasypvp2 жыл бұрын
I write my web servers in rust. (crab rave intensifies)
@elliotmarks062 жыл бұрын
As hard as this may have been, it's crazy how much you can still do with a 50-year-old programming language. Yes, I was also caught off guard when I learned that C is 50 years old.
@woooooooooow2 жыл бұрын
i got rick roll in a c++ video on youtube, truly a masterpiece
@jamesmnguyen2 жыл бұрын
1:03 Why did I instantly know what was going to happen next.
@imraninfrarote2 жыл бұрын
Human brains have amazing pattern recognition.
@parthokr2 жыл бұрын
"0 hours and 69 minutes of thinking"
@homerlol90582 жыл бұрын
I can't wait for the next episode
@colinmaharaj2 жыл бұрын
I actually had written a web server, in C++ Builder, and integrated it in a rich GUI app. That's what I used to make the app available on the web.
@imraninfrarote2 жыл бұрын
That's actually amazing!
@colinmaharaj2 жыл бұрын
@@imraninfrarote Honestly, I have been writing that code and maintaining it for a long time, so it wasn't an over night success. Maybe over many nights . 😂
@anantawijaya15942 жыл бұрын
holy shit, never thought about this. my language when i first entered university
@nullifydiablo2 жыл бұрын
Nice video. Just to let you know, hash collisions are extremely rare for most hash functions.
@imraninfrarote2 жыл бұрын
Yeah. But I really wanted to try out a BST. I'm still learning
@AlFredo-sx2yy2 жыл бұрын
huh, looks like someone hasnt used a hash function in their entire life!
@rileyfletch2 жыл бұрын
Are you so sure about that
@RoadToFuture007 Жыл бұрын
It only depends on how wide your hashtable is and how much data you have. If your hashmap is N buckets big and you have to make N + 1 entries, guess what? You will have at last 1 collision (or even more) - inevitable! No mater how good your hash function is.
@jenreiss31072 жыл бұрын
"I used a BST cuz I didn't wanna roll my own HashMap" god I love rust
@jenreiss31072 жыл бұрын
inb4 no_std killaz
@jjjannes2 жыл бұрын
There is a really old framework to write websites in C named FCGI, it's a bit easier then writting your own webserver.