2018-10-10 18:03:03 -04:00
---
id: 5900f4c81000cf542c50ffdb
2021-02-06 04:42:36 +00:00
title: 'Problem 348: Sum of a square and a cube'
2018-10-10 18:03:03 -04:00
challengeType: 5
2021-02-06 04:42:36 +00:00
forumTopicId: 302007
2021-01-13 03:31:00 +01:00
dashedName: problem-348-sum-of-a-square-and-a-cube
2018-10-10 18:03:03 -04:00
---
2020-12-16 00:37:30 -07:00
# --description--
2018-10-10 18:03:03 -04:00
2021-02-06 04:42:36 +00:00
Many numbers can be expressed as the sum of a square and a cube. Some of them in more than one way.
2018-10-10 18:03:03 -04:00
2021-02-06 04:42:36 +00:00
Consider the palindromic numbers that can be expressed as the sum of a square and a cube, both greater than 1, in exactly 4 different ways. For example, 5229225 is a palindromic number and it can be expressed in exactly 4 different ways: 22852 + 203 22232 + 663 18102 + 1253 11972 + 1563
2018-10-10 18:03:03 -04:00
2021-02-06 04:42:36 +00:00
Find the sum of the five smallest such palindromic numbers.
2018-10-10 18:03:03 -04:00
2020-12-16 00:37:30 -07:00
# --hints--
2018-10-10 18:03:03 -04:00
2021-02-06 04:42:36 +00:00
`euler348()` should return 1004195061.
2018-10-10 18:03:03 -04:00
```js
2020-12-16 00:37:30 -07:00
assert.strictEqual(euler348(), 1004195061);
2018-10-10 18:03:03 -04:00
```
2021-01-13 03:31:00 +01:00
# --seed--
## --seed-contents--
```js
function euler348() {
return true;
}
euler348();
```
2020-12-16 00:37:30 -07:00
# --solutions--
2020-08-13 17:24:35 +02:00
2021-01-13 03:31:00 +01:00
```js
// solution required
```