0

I'm really new to programming just started last week, and i have a problem where my c-file doesn't recognize the cs50.h file when it's in the same folder as my program. i have msys2 installed.

I don't know how to proceed.

Jonathan Leffler
  • 730,956
  • 141
  • 904
  • 1,278
Khacke
  • 5
  • 2

1 Answers1

1

Using <header_here.h> takes them from some system wide directory (not sure for windows but for linux it is /usr/include/ that has these header files. For the current path use #include "headername_here.h" instead.

#include "cs50.h"
drk1
  • 65
  • 11
  • Sorta, but the search path is more complex that just `/usr/include`. It usually includes `/usr/local/include`, for instance, and may well include some other directories. There are other nuances to the search algorithm too. – Jonathan Leffler Oct 30 '22 at 02:56