Thread: Beginner practicing

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User
    Join Date
    Apr 2022
    Posts
    4
    Quote Originally Posted by john.c View Post
    You just need to remove the word 'float' from the scanf call.
    Thank you for the reply. I'm just curious as to why the compiler states "expected expression before float" because that to me says there's nothing wrong with having float itself there, but you're just missing something before the word float? Is that just something you have to get used to in working with these compilers?

  2. #2
    Registered User
    Join Date
    Feb 2022
    Location
    Canada, PEI
    Posts
    103
    It could be that you are trying to take the address of a key word and the compiler is looking for an expression that it can take the address of.

    Address-of operator: & | Microsoft Docs

    From the above link:

    Syntax

    address-of-expression:
    & cast-expression
    Last edited by G4143; 04-20-2022 at 07:00 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. practicing memory management
    By deathslice in forum C Programming
    Replies: 4
    Last Post: 02-26-2016, 08:29 PM
  2. Replies: 18
    Last Post: 08-04-2011, 09:47 PM
  3. Google practicing Voodoo in Europe
    By MK27 in forum General Discussions
    Replies: 18
    Last Post: 07-14-2010, 11:09 PM
  4. Still Practicing, Too Much To Learn
    By dolfaniss in forum C Programming
    Replies: 6
    Last Post: 05-21-2010, 01:27 PM
  5. Windows programming for beginner (Absolute beginner)
    By WDT in forum Windows Programming
    Replies: 4
    Last Post: 01-06-2004, 11:21 AM

Tags for this Thread