デッキが、第一色の単色、第二色の単色、第一色と第二色を含む多色のカードのみで構成されていると仮定してシミュレーション。
色事故を全く考慮しなかった場合の厳密解は、76.4%。
1ターン目の手札(枚) | 5 | 5 | 5 | 5 | 5 | 5 | 5 | 5 |
《一撃奪取》(枚) | 4 | 4 | 4 | 4 | 4 | 4 | 4 | 4 |
《虹彩奪取》(枚) | 4 | 4 | 4 | 4 | 4 | 4 | 4 | 4 |
多色(枚) | 4 | 6 | 4 | 6 | 8 | 4 | 0 | 12 |
第二色の単色(枚) | 4 | 4 | 6 | 6 | 4 | 8 | 12 | 0 |
第一色の単色(枚) | 24 | 22 | 22 | 20 | 20 | 20 | 20 | 20 |
2ターン目着地(%) | 70.7 | 72.5 | 72.6 | 74.0 | 73.9 | 73.9 | 73.0 | 73.6 |
※同じ条件でも、0.1%ずれることがあった。
2ターン目の都合だけ考えれば、多色と単色の比率はあまり関係ない。と、いうより第二色の枚数を少し変えた程度では大した差がない……
迷ったら、強いカードを入れるのが良い。
奪取.exe
以下ソース
using System; using System.Collections.Generic; using System.Linq; namespace StartDash { class Program { static void Main(string[] args) { int[] deck = Calc.Deck(); int result = 0; int loop = 1000000; for (int i = 0; i < loop; i++) { if (Calc.Check(deck.Shuffle().ToArray())) result++; } result = result / (loop / 10000) + 5; result /= 10; Console.WriteLine(Calc.resultMessage + ":約" + result / 10 + "." + result % 10 + "%"); Console.ReadLine(); } } public static class IEnumerableExtension { public static IEnumerable<T> Shuffle<T>(this IEnumerable<T> collection) { return collection.OrderBy(i => Guid.NewGuid()); } } }
using System; namespace StartDash { class Calc { static int startinghand; static int startdash; static int rainbowdash; static int color_sub; static int multi; static int cardsInDeck; public static string resultMessage = "2ターン目に一撃(虹彩)奪取を出せる確率"; public static void Enter() { Console.WriteLine("1ターン目の手札の枚数(先5、後6)"); startinghand = int.Parse(Console.ReadLine()); Console.WriteLine("一撃奪取の枚数"); startdash = int.Parse(Console.ReadLine()); Console.WriteLine("虹彩奪取の枚数"); rainbowdash = int.Parse(Console.ReadLine()); Console.WriteLine("サイドカラー単色枚数"); color_sub = int.Parse(Console.ReadLine()); Console.WriteLine("多色の枚数"); multi = int.Parse(Console.ReadLine()); //startinghand = 5; //startdash = 4; //rainbowdash = 4; //color_sub = 0; //multi = 12; cardsInDeck = 40; } public static bool Check(int[] deck) { bool result = false; int mana_main = 0; int tapin = 0; //一撃 for (int i = 0; i < startinghand + 1; i++) { if (deck[i] == 2) { mana_main++; result = true; } else if (deck[i] == 6) mana_main++; else if ((deck[i] & 3) == 3) { mana_main++; tapin++; } } //一撃が存在、アンタップインが他に1枚以上、第一色が2枚以上 if (result && tapin != startinghand && mana_main > 2) return true; //虹彩 result = false; mana_main = 0; tapin = 0; int mana_sub = 0; for (int i = 0; i < startinghand; i++) { if (deck[i] == 3) { mana_sub++; mana_main++; tapin++; result = true; } else if (deck[i] == 7) { mana_sub++; mana_main++; tapin++; } else if (deck[i] == 6) mana_main++; else if (deck[i] == 5) mana_sub++; } //虹彩が存在する if (result) { //すべてタップインなら、デッキトップが単色 if (tapin == startinghand) return (deck[startinghand] & 3) != 3; //第二色が1枚 if (mana_sub < 2) { //虹彩が唯一の第二色だった場合 //デッキの残りの虹彩の枚数が、第二色の単色より多ければ、唯一の虹彩をマナにする //デッキトップと対話できる人は考慮しない if (color_sub < rainbowdash - 1) return deck[startinghand] == 3; return deck[startinghand] == 5; } //第一色が1枚なら、デッキトップが第一色の単色 if (mana_main < 2) return deck[startinghand] == 6; return true; } //虹彩が存在しない //デッキトップが虹彩 else if (deck[startinghand] == 3) { //アンタップインが1枚以上 if (tapin == startinghand) return false; //第一色が1枚以上 if (mana_sub < 1) return false; //第二色が1枚以上 if (mana_main < 1) return false; return true; } return false; } public static int[] Deck() { Enter(); int[] deck = new int[40]; int j = 0; //一撃 for (int i = 0; i < startdash; i++) { deck[j] = 2; j++; } //虹彩 for (int i = 0; i < rainbowdash; i++) { deck[j] = 3; j++; } //第二色 for (int i = 0; i < color_sub; i++) { deck[j] = 5; j++; } //多色 for (int i = 0; i < multi; i++) { deck[j] = 7; j++; } //第一色 for (int i = j; i < cardsInDeck; i++) { deck[j] = 6; j++; } return deck; } } }