٥륯åĥ
3321̤
33116-33̤
322112-66̤
3211120̤
3111116̤
222111̤
22111115-510̤
21111117̤
111111111̤
ƻĴ٤ƹ55̤ˤʤޤ
422ڡ 0:15:34 50405
ߤ뤯
8餤ʤץ񤯤Τȼ׻ǿΤɤäᤤ̯ʥ饤Ǥ͡
#include "bits/stdc++.h"
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rep2(i,l,r)for(int i=(l);i<(r);++i)
#define endl "\n"
long long dp[1000][4];
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n = 8;
int m = 3;
dp[0][0] = 1;
rep(i, n) {
rep(j, m + 1) {
rep2(k, 1, m + 1) {
if ((j == k) && (k > 1))continue;
dp[i + k][k] += dp[i][j];
}
}
}
long long ans = 0;
rep2(i, 0, m + 1) ans += dp[n][i];
cout << ans << endl;
return 0;
}
422ڡ 0:21:01 50406
ߤ
֣¤ǣ롣İʾĤʤ롢İʾĤʤΤԲġ
ȹͤ롣
Ǹ˲äǾʬĤġäݤ򤯤Τ᤽
ʲɽǺ¡ʿˤģξɽ

Ǹ夬
Ǹ夬
Ǹ夬

ɽθ
Ǹ夬ǣˤʤΤϡʤξκǸ夬ܺǸ夬ܺǸ夬ܣܣᣳ
Ǹ夬ǣˤʤΤϡʤξκǸ夬ܺǸ夬ܣᣱ
Ǹ夬ǣˤʤΤϡʤξκǸ夬ܺǸ夬ܣ᣹

ʤξιפϡܣܣᣵ̤ꡣ
422ڡ 0:26:57 50407
鯤ο
#50407
ŪƱǤ
nʤξβAnȤȡ
A8=A7+(A6⡢Ǹ夬2ʳΤ)+(A5⡢Ǹ夬3ʳΤ)
A6ޤǤ񤭽ФơA8=32+14+955̤ꡣ
//
422ڡ 0:36:07 50409
鯤ο
#50407
ŪƱǤ
nʤξβAnȤȡ
A8=A7+(A6⡢Ǹ夬2ʳΤ)+(A5⡢Ǹ夬3ʳΤ)
A6ޤǤ񤭽Фơ
A7=19+8+532
A8=32+14+955̤ꡣ
//
422ڡ 0:39:41 50410
⡼ޥ
ְ㤤ޤ..^^;

׻ޤ ^^;;

f(1)=1
f(2)={11,2}=2
f(3)={111,12,21,3}=4
f(4)=1+2+4=7
f(5)=2+4+7=13
f(6)=4+7+13=24
f(7)=7+13+24=44
f(8)=13+24+44=81

줫...ʲΥ
111145
1163
1346
1124214,412...2*3=6,116...39
22221
262

so...5+3+6+9+1+2=26
...
81-26=55

⤦ OrZzzz
422ڡ 1:28:04 50411
ߤ
(#50403 #50404

ؤβΤäƤȥࡼ˲򤱤äơΤ褦ʳʾ
ˤ䡢
֤ߤ󣵸Ĥ򣳿ͤʬˡϲ̤ꤢ뤫סʽʣȤ߹碌
֣⣹ޤޤʤʾǣܤϲסʣˡ
ʤƤΤ⤢ʤȹͤƤ麣ν꤬ˤƤ
ۤɤۤɤ٤ǡ̤˲򤤤Ƥ⽽ʬ#50405ˤǤ͡ʤʤ
̤ꡢʤȣ̤ꡣ

θͥϤäѤؤǤμˤϿؤϰϤǤ
ͤ⤤ȤϻפɡΰտޤʬäͤϤΤʤȲ򤤤
󤰤餤м̼ʤȤͭɡԤʤ
ꤹ̣ޤ͡ΰտޤ򤷤ȤƤ⡢Σ׻
ΤϤʤ꤭Ĥ

¾γδۡ餱ˤߤʤɤޤˤϸۤɡ
422ڡ 1:37:22 50412
baLLjugglermoka
110¤55ƱʤΤ϶Ǥ͡
422ڡ 1:39:05 50413
̴
#50405
եܥʥåʤɤƬ򤫤ޤɤ⤦ޤ
ܤꡢ٥륯åĥͤƱ褦
򤭤ޤ
ٻΤ桡 422ڡ 8:14:08 50414
Ȥ
Basic

for a=1 to 3
for b=1 to 3
if (a=2 and b=2) or (a=3 and b=3) then goto 70
for c=1 to 3
if (b=2 and c=2) or (b=3 and c=3) then goto 60
if a+b+c=8 then let s1=s1+1
for d=1 to 3
if (c=2 and d=2) or (c=3 and d=3) then goto 50
if a+b+c+d=8 then let s2=s2+1
for e=1 to 3
if (d=2 and e=2) or (d=3 and e=3) then goto 40
if a+b+c+d+e=8 then let s3=s3+1
for f=1 to 3
if (e=2 and f=2) or (e=3 and f=3) then goto 30
if a+b+c+d+e+f=8 then let s4=s4+1
for g=1 to 3
if (f=2 and g=2) or (f=3 and g=3) then goto 20
if a+b+c+d+e+f+g=8 then let s5=s5+1
for h=1 to 3
if (g=2 and h=2) or (g=3 and h=3) then goto 10
if a+b+c+d+e+f+g+h=8 then let s6=s6+1
10 next h
20 next g
30 next f
40 next e
50 next d
60 next c
70 next b
80 next a
print s1;"+";s2;"+";s3;"+";s4;"+";s5;"+";s6;"+";s7;"+";s8;"=";s1+s2+s3+s4+s5+s6+s7+s8

f9 1 + 9 + 21 + 16 + 7 + 1 + 0 + 0 = 55()

ᤴƤޤäǤץ5ʬ餤
񤱤Τ٤ץξȻפޤ!!
˭ԡ 422ڡ 8:15:28 MAIL:fttnm528@ybb.ne.jp 50415
ֿء׾ι
ޥܤ˽񤭹ǤλǤޤ
ñʤϤΤʤ
422ڡ 9:09:57 50416
ֿء׾ι
RubyǥץǤƵƤӽФȤäƤޤ

$n=0

def f(s,a)
s+=a
if s<=8 then
if s== 8 then
$n+=1
else
for i in [1,2,3]
if (a == 1) or (i != a) then
f(s,i)
end
end
end
end
end

f(-1,1)
p $n
422ڡ 11:24:54 50417
ߤ
Τ¾δۤʤɤǤ

ʣ˾佸
׻
뤦ǯβդ׻Уϣˡĥ顼θΤäƤͤ⤤
ȤϻפʣdzФˤ
ҳرʻȴˤǤ⡢֣ǯϲפꡣ
ǯ䣲ǯʤ飱ǯ䤦⤱ää
ޤʤǤǥ֤ͥꡩ

§
ɤǸȤΤȤꤢȤ򤹤ˡ§ϸϤ

ʿ̿޷
ϻѷѷʬ䤷ѤФȤפӥꡣ


פΤǡܤ褯۴ľdzھȻפġ
Ȥꤢ׻򤹤ȡΣȴطꤽʤΤ˵ŤΤǡ裴̤
롣Σ褬ˤʤȷ̤ˤɤƶ뤫ʬˤᡢ
̰ʹߤϤäˤäȤƤ⡢Σ򤫤ʤ׻ʤƤϤʤ餺
ʣʹߤäƤޤФƤʤ͡˷׻ߥΥꥹ⤽

ʣΩΤ
ܤϲ򤱤ޤäΤǤˤΤǤϰäƤꡣ
̣ϤʤֲˡΤäƤ뤫Ȥʤ롢Ǥʢ餱ˤߡˡ
ȤΩο޷äΤϤʤˤʤä褦ʵġ

ʣ˻ԺȤʤ
ܤƳܤȤ򤬤ФФǤȻפޤ
ˡη׻Υơޤ餷ǤˤʤʤդˤϤʤΤ
ǸΣܤϤ֤ΤꡣƻĴپ夲ǽäѡ
Τ֤в򤱤Τǡ˽椷ƼݤΤ⥢ꡣǤ
ֲ̤ꤢ뤫פ䤦ƤΤǡ̤񤭽ФƤʤƤǤʬϴ

ޤȤ
ʣˡݣʣˤΣܤϰפʤΤǡ¨ȡ
ʣˤΩο޷ǤФȤڡǤʤСʣˤΣܤޤ
ɤ夯Ȥɬפ
פΤŪȤȡפ佸Ρʣˤ򥫥åȤơ
ƼȤ䣴Ĥ褦˻פޤ棲ܤȤ
ǤäȤ餤Ǥ礦ɤΤǤϡ
422ڡ 12:33:46 50418
Ϸ
ǽϥեܥʥå󤫤ʤȻפޤޤޤ
ǡ夲Ƥ55ˤɤ夭ޤ

θ塢եܥʥå󤫤鲿ƤߤФȡäƤߤޤ
4ܡ5ȿ夲Τ褦ˤʤޤ
1124ȥեܥʥåˤʤޤ
423ʶ 11:10:34 MAIL:takaaki-k@aqr.bbiq.jp 50419
Mr.ǥ
ʤФο򡡣(n)
Τ
1⤬1ʡ2ʡ3ʤξο򤽤줾졡a1(n),a2(n),a3(n)Ȥ
A(n)=a1(n)+a2(n)+a3(n)

a1(n+1)=A(n)
a2(n+1)=A(n-1)-a2(n-1)
a3(n+1)=A(n-2)-a3(n-2) .(n2


a1(1)=A(1)=1
a1(2)=a2(1)=1 ,a3(2)=0......A(2)=1+1+0=2
a1(3)=A(2)=2 ,a2(3)=A(1)=1,a3(3)=1......A(3)=2+1+1=4

a1(4)=A(3)=4 ,a2(4)=A(2)-a2(2)=2-1=1,a3(4)=A(1)=1......A(4)=4+1+1=6
a1(5)=A(4)=6 ,a2(5)=A(3)-a2(3)=4-1=3,a3(5)=A(2)=2......A(5)=6+3+2=11
a1(6)=11 ,a2(5)=6-1=5,a3(6)=3......A(6)=11+5+3=19
a1(7)=19 ,a2(7)=8,a3(7)=5......A(7)=19+8+5=32
A(8)=32+14+9=55
(äȳڤˡꤽʡ

423ʶ 11:37:58 50420

錄ۤȤMr.ǥƱǺǸ夬1ʡ1Ф2ФǤnʤФA(n)B(n)C(n)Ȥȡ
A(n+1)=A(n)+B(n)+C(n)
B(n+2)=A(n)+C(n)
C(n+3)=A(n)+B(n)
A(1)=1,B(1)=0,C(1)=0,B(2)=1,C(2)=0,C(3)=1ʤΤǡ
A(2)=A(1)+B(1)+C(1)=1
A(3)=A(2)+B(2)+C(2)=2
B(3)=A(1)+C(1)=1
A(4)=A(3)+B(3)+C(3)=4
B(4)=A(2)+C(2)=1
C(4)=A(1)+B(1)=1
A(5)=6, B(5)=3, C(5)=2
A(6)=11, B(6)=5, C(6)=3
A(7)=19, B(7)=8, C(7)=5
A(8)=32, B(8)=14, C(8)=9
ä32+14+9=55̤
423ʶ 17:53:04 50421
ʻ˥󥸡
֥URLǤhttps://nannkainasannsuunityarennzi.hatenablog.com/
423ʶ 20:50:07 50422
Ф
ɽꡢϤstepˤϡФstepˤϡߤĤ
ʤ򣱤ĤĤդ䤷ޤϤ62ȤΤ
ФƤ줺ѤʤȤäȻפäƤޤ

󤿤#50421
3ιȤŪñ˹ԤʤǤ͡դޤǤ
424ڡ 7:16:04 50423
hrgn
mathematicaǤޤ

dp[1, 0] = 1;
dp[2, 1] = 1;
dp[3, 2] = 1;
dp[n_ /; n < 1, 0] := 0;
dp[n_ /; n < 2, 1] := 0;
dp[n_ /; n < 3, 2] := 0;
dp[n_, 0] := dp[n, 0] = dp[n - 1, 0] + dp[n - 1, 1] + dp[n - 1, 2];
dp[n_, 1] := dp[n, 1] = dp[n - 2, 0] + dp[n - 2, 2];
dp[n_, 2] := dp[n, 2] = dp[n - 3, 0] + dp[n - 3, 1];
ans = dp[8, 0] + dp[8, 1] + dp[8, 2]
424ڡ 23:39:02 50424
ɥȥ
եܥʥåȥܥʥåѤʤȸơĴپ夲ޤ
#50407٥륯åĥβˡˤʤޤ
ˤι˺ƤȤ˿˵Ť
ƬDz򤤤ƤȻפäΤ᡹꥿ⵡǽȤޤ
425 7:30:00 50425
ɥȥ

#50405Ǥ
줬12ʤȤˤʤä顢#50407ߤ󤵤βˡǤ礦͡
425 7:39:37 50426
ʻ˥󥸡
ʻ˥󥸡URLhttps://www.kikuya-rental.com/bbs/?owner_name=nannkainasannsuuˤԷǼĤޤ
425 9:37:11 50427
ʻ˥󥸡
URLְäƤޤϤǤhttps://nannkainasannsuunityarennzi.hatenablog.com/
425 9:38:21 50428
ޤ륱
#50407 ߤ󤵤βˡ#50417 ֿء׾ιԤΥץ˿ȯޤơ
פ֤ ruby 饤ʡƤߤޤäĹǤ

p Hash.new{|h,k|h[k]=k<3?[(k+4)/3,(k+2)/3,(k+1)/3]:[h[k-1].sum,h[k-2][0]+h[k-2][2],h[k-3][0]+h[k-3][1]]}[7].sum
425 18:08:12 50429
SECOND
BASIC Ǥ12ʤޤǤäƤߤޤäƤ饴

FOR y=1 TO 12
LET sum=0
CALL octa(0,0)
PRINT USING"! ## #### ̤": y,sum
NEXT y

SUB octa(k,p)
LET s=s+p !k ޤǤʿ
IF y=s THEN !y
LET sum=sum+1 !y ʤ߷
ELSEIF s< y THEN !y ̤
CALL octa(k+1,1) !1ɲ
IF p<>2 THEN CALL octa(k+1,2) !Ϣ³2ɲ
IF p<>3 THEN CALL octa(k+1,3) !Ϣ³3ɲ
END IF
LET s=s-p !k ʿ cancel
END SUB

END

!¹Է̡
! 1 1 ̤
! 2 2 ̤
! 3 4 ̤
! 4 6 ̤
! 5 11 ̤
! 6 19 ̤
! 7 32 ̤
! 8 55 ̤
! 9 95 ̤
! 10 163 ̤
! 11 280 ̤
! 12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3 THEN CALL octa(3) !Ϣ³3ɲ
END IF
LET s=s-p !p ɲä cancel
END SUB
428ʿ 2:35:58 50438
Ф
ޥ뤵󡢤٤ߤʤΤǡʤΤɤǤ硣
ʬ

xyzľx0y0z0xyyzzx棳xyz6
ʬѤ᤿ΩΤˤĤ
x+y+z=tڤäѤʤ
Ѥʤ
429ڡ 5:24:04 50439
kyorofumi
#50434
ֿ꤬ȤޤгѲǤȰ̹बƳФȤΤϳΤǼǤǤ
ǽξ壳ʤƲ⤤гѲǤʤȤʤǤ͡
ޤгѲδطˤĤĴ٤Ƥߤޤ
429ڡ 5:43:13 50440
Ф
#50439
פߤäơ褯ߤȴְ㤤ꤽǤƤ

xyzľǡx2+y2+z2+xyyzzx6
ʬѤ᤿ΩΤˤĤ
x+y+z=tڤäѤʤ
Ѥʤ
429ڡ 6:55:22 50441
Ϸ
ȤäƤߤޤ
Τ褦ɽޤ
顡ʿ
ʿʤο

1ʤȤФξ
2ʤȤФξ
סܭܭ
1έܭܭ
2έܭ
3έܭ
η׻򥨥ˤ餻ޤ
50420Σͣ򡥥ǥƱ褦Ǥ
429ڡ 9:35:42 MAIL:takaaki-k@aqr.bbiq.jp 50442

񤤽Τ桹񤷤Ȼפ۵޻ʤɡ
²ͤǡܤ˹Ԥäޤ

ޥ뤵ˤ̵񤤽衢ĥ
ޤäʤ桢˱Фĺ
˴ưޤ

졼餫̣²­ǡ
̤ϡ󤴾̣ĺФȻפޤ

ûʤ⡢ڤ֤򤢤꤬Ȥޤ
Ȥ⡢ꤤפޤ
51ڡ 16:26:46 50443
ޥ
#50443
绳󡢤餳񤤤Ǥƴ㤤ޤ󤤤Ȥ虜虜ۤˤ꤬Ȥޤʤ줫ī&#12316;15:30餤ޤǡŹˤޤʤŻɡڤǤ
𡡡 53ʷ 9:56:40 HomePage:ARENA50444