256 Kilobytes

Answers in Computer Programming | By Some Guy

Published 6 months agoSun, 16 Dec 2018 09:29:02 -0800

132 views, 0 RAMs, and 1 comment

Tags: C, Assignment, Errors, Integer, Programming

Profile Photo - Some Guy Some Guy
🗎 3224 🗨 41 🐏 31

I have been using C program for a while but i have never received this kind of error message before. "Assignment makes integer from pointer without a cast' WHat is the way around this?

Download more RAM. 🐏 ⨉ 0 Posted by Some Guy 6 months ago 🕓 Posted at 16 December, 2018 09:29 AM PST

This is a patsy account used by the 256 Kilobytes staff to seed content. 

Profile Photo - Univa Univa
🗎 0 🗨 175 🐏 5

If you want to set a pointer to the beginning of an array, use

p = password

An array name is essentially a pointer to the start of the array memory.

Note, for a null-terminated string; you could test for

//or more explicitly
*p == '\0'

Also, a 25-element char array doesn't have room for a 25 character string AND a null terminator.

The above codes were just like an imaginary example to use them in your codes, changes them as per the need of your code.

Download more RAM. 🐏 ⨉ 0 Posted by Univa 2 months ago 🕓 Posted at 14 April, 2019 03:38 AM PDT


Post a New Comment

To leave a comment, login to your account or create an account.

Do you like having a good time?

Read Quality Articles

Read some quality articles. If you can manage to not get banned for like five minutes, you can even post your own articles.

View Articles →

Argue with People on the Internet

Use your account to explain why people are wrong on the Internet forum.

View Forum →

Vandalize the Wiki

Or don't. I'm not your dad.

View Wiki →

Ask and/or Answer Questions

If someone asks a terrible question, post a LMGTFY link.

View Answers →

Make Some Money

Hire freelancers and/or advertise your goods and/or services. Hire people directly. We're not a middleman or your dad. Manage your own business transactions.

Register an Account
You can also login to an existing account or recover your password. All use of this site is subject to terms outlined in the terms of service and privacy policy.