<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0">
  <channel>
    <title>Homework Help! - C++ - tribe.net</title>
    <link>http://cpp.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55?format=rss</link>
    <description>Tribe.net. Local Connections</description>
    <item>
      <title>Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#be61cf58-84e4-4b27-8be6-db5fda2d5681</link>
      <description>Alright, i told y'all you'd be helpin me soon&#xD;
&#xD;
heres my first problem:&#xD;
Why is this function telling me that i'm not using an array?&#xD;
i passed it an array with the x and y floats but i keep geting the error, or should they not be floats?&#xD;
&#xD;
float segmentLength(float, float, float, float);&#xD;
float polygonPerimeter (float x, float y, int pnts)&#xD;
{&#xD;
	float d;&#xD;
	int i;&#xD;
	for (i=0; i&amp;amp;lt;pnts; i++);&#xD;
	&#xD;
		d = segmentLength (x[i], x[i+1], y[i], y[i+1]);&#xD;
&#xD;
	return 0;</description>
      <pubDate>Tue, 16 Mar 2004 21:20:41 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#be61cf58-84e4-4b27-8be6-db5fda2d5681</guid>
      <dc:creator>Zack</dc:creator>
      <dc:date>2004-03-16T21:20:41Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#0e0dc2c9-cb95-412e-8548-85886332dd45</link>
      <description>IT's telling you x and y are not arrays because you have declared them as floats. They should be *(float* x, float* y, int pts)&#xD;
It doesn't matter what you call it with if you declare it improperly.</description>
      <pubDate>Tue, 16 Mar 2004 23:46:14 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#0e0dc2c9-cb95-412e-8548-85886332dd45</guid>
      <dc:creator>Bill</dc:creator>
      <dc:date>2004-03-16T23:46:14Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#e66355ae-bf5c-4f09-9889-21f04d6ce956</link>
      <description>Without the star in front of the parenthesis. I think tribe did that. That's what I get for not previewing.</description>
      <pubDate>Tue, 16 Mar 2004 23:47:16 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#e66355ae-bf5c-4f09-9889-21f04d6ce956</guid>
      <dc:creator>Bill</dc:creator>
      <dc:date>2004-03-16T23:47:16Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#c3ca024a-2f2f-4851-be03-d006212d6a9a</link>
      <description>but when i do that it just gives me  a different error, i think it was "array or pointer type" error. so does that mean the problem is back in the 'main' funtion?&#xD;
&#xD;
also, i guess i should have said the purpose of this funtion is to give the perimeter of a polygon. not that that changes the situation.</description>
      <pubDate>Wed, 17 Mar 2004 06:40:22 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#c3ca024a-2f2f-4851-be03-d006212d6a9a</guid>
      <dc:creator>Zack</dc:creator>
      <dc:date>2004-03-17T06:40:22Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#1b5c08e1-9a33-4576-9402-ba5b32dea9b6</link>
      <description>This compiles fine, at least on its own (notice that I got rid of the semicolon at the end of the for also, this was an empty for followed by one single segmentLength execution). If there is any other problem it is in the caller of polygonPerimiter or within segmentLength. Try to follow all the other changes and figure out why I did them. Each one is important.&#xD;
&#xD;
float segmentLength(float, float, float, float); &#xD;
float polygonPerimeter (float *x, float *y, int pnts) &#xD;
{ &#xD;
  float d=0.0; &#xD;
  int i; &#xD;
  for (i=0; i&amp;amp;lt;pnts; i++)&#xD;
    d += segmentLength (x[i], x[i+1], y[i], y[i+1]); &#xD;
&#xD;
  return d; &#xD;
}</description>
      <pubDate>Wed, 17 Mar 2004 15:13:26 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#1b5c08e1-9a33-4576-9402-ba5b32dea9b6</guid>
      <dc:creator>Bill</dc:creator>
      <dc:date>2004-03-17T15:13:26Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#263d1c81-1ffb-4dec-90d2-ba5a4d4e97cf</link>
      <description>hint: I left one major problem for you.</description>
      <pubDate>Wed, 17 Mar 2004 15:15:15 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#263d1c81-1ffb-4dec-90d2-ba5a4d4e97cf</guid>
      <dc:creator>Bill</dc:creator>
      <dc:date>2004-03-17T15:15:15Z</dc:date>
    </item>
    <item>
      <title>Re: Homework Help!</title>
      <link>http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#4b77a8da-c6fc-4b78-9f17-3be2ea812372</link>
      <description>Yikes! This is C, not C++.</description>
      <pubDate>Tue, 23 Mar 2004 22:54:45 GMT</pubDate>
      <guid isPermaLink="false">http://CPP.tribe.net/thread/78170b9a-a4e7-4420-905b-05ca95363f55#4b77a8da-c6fc-4b78-9f17-3be2ea812372</guid>
      <dc:creator>Bartosz</dc:creator>
      <dc:date>2004-03-23T22:54:45Z</dc:date>
    </item>
  </channel>
</rss>



