あにす #3781(2007/11/09 18:09 GMT) [ VB.net ] Rating0/0=0.00
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
Private Function mamakodate(ByVal n As Integer, ByVal k As Integer, ByVal m As Integer) As Integer 'カードを並べる Dim List As New List(Of Integer) For i As Integer = 0 To n - 1 List.Add(i + 1) Next Dim index As Integer = m - 1 While List.Count <> 1 List.RemoveAt(index) index += k - 1 While index > List.Count - 1 index -= List.Count End While End While Return List(0) End Function
Rating0/0=0.00-0+
[ reply ]
あにす
#3781()
[
VB.net
]
Rating0/0=0.00
m = 100000
k = 100000
66029
4.921875秒
Rating0/0=0.00-0+
[ reply ]