我是編程新手。所以,細節表示讚賞。編譯器顯示「作爲賦值左操作數所需的錯誤左值」。這是什麼意思,以及如何解決它?
#include<stdio.h>
#include<math.h>
int main()
{
float x, f(x);
printf("Enter x=");
scanf("%f", &x);
f(x)= 3*pow(x, 5)- 5*sqrt(x)-6*sin(x); /*in this line compiler shows error*/
printf("f(x)= %f", f(x));
return 0;
}
http://code.geeksforgeeks.org/5x2pXV – rsp
@rsp回答這個問題的評論應該是答案。僅編輯鏈接的答案應進行編輯以提供解釋,而不要求讀者對外訪問。 – Yunnosch
如果你是新手,想要學習C語言,[**好書**](https://stackoverflow.com/questions/562303/the-definitive-c-book-guide-and-list)將首先爲您服務,特別是作爲語法,語言細節和圖書館的參考。我懷疑你正在嘗試[做這樣的事情](http://ideone.com/mYEsD6),但你應該花費用來學習更多關於語言的知識並理解它的工作原理。 – WhozCraig