A roadside vegtable stand sells pumpkins for $5 each and squashes for $3 each. One day they sold $6 more squash than pumpkins, and their sales totaled $98. Write and solve a system of equations to find how many pumpkins and squash they sold?

s=p+6

5p+3s=98

p=13 s=19

To solve this problem, let's consider the number of pumpkins and the number of squashes sold.

Let's assume the number of pumpkins sold is "x", and the number of squashes sold is "y".

Given:
The price of each pumpkin is $5, so the total revenue from pumpkins is 5x.
The price of each squash is $3, so the total revenue from squashes is 3y.

We also know that they sold $6 more squash than pumpkins, which can be expressed as:
y = x + 6

The total sales revenue is given as $98, so we can form another equation:
5x + 3y = 98

Now, we have a system of equations:
Equation 1: y = x + 6
Equation 2: 5x + 3y = 98

To solve this system of equations, we can substitute the value of y from Equation 1 into Equation 2:
5x + 3(x + 6) = 98

Simplifying the equation:
5x + 3x + 18 = 98
8x = 98 - 18
8x = 80
x = 10

Now, we can substitute the value of x into Equation 1 to find the value of y:
y = 10 + 6
y = 16

Therefore, the number of pumpkins sold is 10, and the number of squashes sold is 16.