Uzerine yaziyorsundur. Pointer kullaniyormusun? Kullaniyorsan malloc ve freelerine dikkatli bak. Ayrica long long icin kutuphane include etmeye gerek yok. Big Int i de kendin yazmadigin surece, 3. parti olarak include etmen gerekir. Istiyorsan kodu PM le bana. |
Ana işlerin olduğu formun üzerine giriş formunu açarsanız sorun olmayacaktır diye düşünüyorum. Bu tarz programlarda genelde kilit nokta bu oluyor. Siz nasıl hazırladınız bilmiyorum, kodları paylaşabilirseniz yardımcı olmaya çalışırım. |
Hepinize öncelikle merhabalar.Cumartesi günü c++ ilk vizem var fakat ben yaklaşık 1aydır hastanede dedmein yanında refakatçi olarak kaldığım için hiçbir derse giremedim ve doğal olarak pek birşey bildiğim söylenemez.Sizlere birkaç vize sorumuzu atttım cevaplarsanız çok mutlu olurum.Hiç yoktan birkaç soruyu ezberleyip notumu yükeselteyim.Teşekkürler hepinize şimdiden :) QUESTION 0 * Suppose that you are asked to develop a cell phone invoice calculator program. * There are two types of tariffs for users: * (1) the users that do not use any package are charged 0.15 TL/6 seconds * (2) the 'eco' package users will pay 19 TL fixed fee for first 50 minutes and 0.2 TL/6 seconds for extra talking time that exceeds 50 minutes * The program will get the total number of talking time in terms of minutes (double type) and then calculate and print the total amount that the user will pay for each tariff type. * Write the C++ source code of the above program. QUESTION 1 Write for and do-while structures to compute the following products. 1 x (1 / 3) x (1 / 5) x ….x (1 / (n/2)) where n is an integer entered by the user. QUESTION 2 Write a C++ program that gets a positive integer from the user. The number will be required until a positive number is entered. Find and print the factors of the entered number. QUESTION 3 #include<iostream> int main() { int i,j,k,n; cout << “How many rows?” << endl; cin >> n; for(i=n; i>0; i=i - 2) { cout << endl; for(k=(i+1)/2; k>0; --k) cout << “ “; for(j=1;j <= i; ++j) cout << “ &”; } } QUESTION 4 Write a C++ program that checks if an entered number is prime or not. QUESTION 5 Write a C++ program that prints the prime numbers between 2 and 10000. QUESTION 6 The value of π can be approximated by using the following series: Write a program that gets the value of n as a parameter and returns the estimated value of π. QUESTION 7 Let n = akak-1ak-2. . .a1a0 be an. Find and display the sum of digits of n (ak + ak-1 + ak-2 + …………… + a1 + a0) The number n will be entered by the user QUESTION 8 The population of a town A is less than the population of town B. However, the population of town A is growing faster than the population of town B. Write a program that prompts the user to enter the population and growth rate of each town. The program outputs after how many years the population of town A will be greater than or equal to the population of town B and the populations of both the towns at that time. QUESTION 9 Write a program that gets 10 elements from the user and displays the minimum. QUESTION 10 Write a program that gets an integer, say n, by the user. The program than will get positive elements by the user until 0 is entered. When 0 is entered, the program will display the position of the last occurance of n. QUESTION 11 Write a program that gets a number from the user and finds the sum of the prime numbers in its digits. |
Arkadaşlar hepsini yapın demiyorum yapabildğinizi yaparsanız çok sevinirim.3 soru 4 soru artık ne kadar yapabilirsek. |
![]() yazdığım kod: ------------------------------ bag.Open(); ekle.Connection = bag; ekle.CommandText = "Delete from kullanici*bilgi Where kullanici*no '" + .CurrentRow.Cells[0].Value.ToString() + "'"; ekle.ExecuteNonQuery(); bag.Close(); listele(); ------------------------------ aldığım hata: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2'' at line 1 < Resime gitmek için tıklayın > |
Bu form2 deki kod form1 de sadece form2 aç butonu ve kull.adı ve şifre giriniz var public partial class Form2 : Form |
#include <iostream> 9. soru biraz özensiz yaptım bu kadar uzun olmamalıydı k.bakma vaktim yoktu oldukça yapıcağım :) |
4. Sorunun cevabı: #include <iostream> |
Çok teşekkür ediyorum.Allah razı olsun.Biliyorum bu soruları siizn çözmeniz benim konuyu anlayacağım anlamına gelmiyor.5 veya 7 gün içerisinde dedemde taburcu oluyor.Böylece eksikliklerime çalışma fırsatım olacak.Tabi önce şu vizeden yüksek bir not almam lazım :) |
Çok teşekkür ederim.Sağolasın.Vaktin olursa eğer diğerlerine de göz gezdirirsen sevinirim :) |
C programlamaya yeni başladım. main.c:(.text+0x3f): undefined reference to `fon' diye bir hata alıyorum ne demek istiyor anlayamadım yardımcı olursanız çok sevinirim.. |
Bunu inceleyin, cevabı burada bulacaksınız. Ek olarak, derdinizi anlatırken düzgün cümle yapıları kullanın. http://stackoverflow.com/questions/4345666/hiding-a-form-and-showing-another-when-a-button-is-clicked-in-a-windows-forms-ap |
fon diye bir fonksiyon kullanmaya çalışmışsınız, fakat bu fonksiyonun bir referansı(prototipi) yok. Fonksiyonun prototipini tanımlanız gerek. En üste yazdığımız (örneğin) int fon(int x, int y) gibi. |
QUESTION 11 Write a program that gets a number from the user and finds the sum of the prime numbers in its digits. Answer #include <iostream>çok karışık oldu comment yazamadım ancak kodu takip edip anlayabilirsin , normalde bu kadar uzun olmamalı amelece oldu biliyorum ama string kullanılarak 3 4 satırda bile yapılabilirdi ama bence hoca bunu aritmetik olarak istiyordur diye düşündüm gerçi aritmetik olsada bu kadar uzun olmamalıydı daha boş bir kafayla yeniden bakıp daha elegance birşey yazacağım şimdilik bu da bir çözüm :) edit Biraz anlatıyım iki fonksiyon oluşturdum biri asal sayı olup olmadığını test ediyor, asalsa true diyor, diğeri ise kaç basamaklı olduğunu buluyor sayının, bir while loopu oluşturdum burada zero - 1 dedim çünkü basamağının 1 eksiği 0 var örneğin 2133 sayısını açarsak 2*10^3 + 10^2 + 3*10^1 + 3*10^1 diye açarız yani 10 üzeri 3 ten baslıyor açılımdaki 10 unun üzeri bende her defasında while loopta bir eksilttim, ancak bu yaptığım programda 4 ve üstü basamağa sahip sayılarda son basamaktaki yani birler basamağındaki sayıyı okutamadım bundan dolayı kontrol ifadesi olan if i kullanarak birler basamağını döngüden önce kontrol ettim ve asalsa ilkin toplama kattım buradan kafana takılan olursa yanıtlamaya çalışırım kardeşim çok geçmiş olsun. |
İlgi ve alakanız için sorularıma vakit ayırdığınız için herkese teşekkür ederim.4. 9. ve 11. soruları çözdük birkaç tane daha kaldı ; QUESTION 0 * Suppose that you are asked to develop a cell phone invoice calculator program. * There are two types of tariffs for users: * (1) the users that do not use any package are charged 0.15 TL/6 seconds * (2) the 'eco' package users will pay 19 TL fixed fee for first 50 minutes and 0.2 TL/6 seconds for extra talking time that exceeds 50 minutes * The program will get the total number of talking time in terms of minutes (double type) and then calculate and print the total amount that the user will pay for each tariff type. * Write the C++ source code of the above program. QUESTION 1 Write for and do-while structures to compute the following products. 1 x (1 / 3) x (1 / 5) x ….x (1 / (n/2)) where n is an integer entered by the user. QUESTION 2 Write a C++ program that gets a positive integer from the user. The number will be required until a positive number is entered. Find and print the factors of the entered number. QUESTION 3 #include<iostream> int main() { int i,j,k,n; cout << “How many rows?” << endl; cin >> n; for(i=n; i>0; i=i - 2) { cout << endl; for(k=(i+1)/2; k>0; --k) cout << “ “; for(j=1;j <= i; ++j) cout << “ &”; } } QUESTION 5 Write a C++ program that prints the prime numbers between 2 and 10000. QUESTION 6 The value of π can be approximated by using the following series: Write a program that gets the value of n as a parameter and returns the estimated value of π. QUESTION 7 Let n = akak-1ak-2. . .a1a0 be an. Find and display the sum of digits of n (ak + ak-1 + ak-2 + …………… + a1 + a0) The number n will be entered by the user QUESTION 8 The population of a town A is less than the population of town B. However, the population of town A is growing faster than the population of town B. Write a program that prompts the user to enter the population and growth rate of each town. The program outputs after how many years the population of town A will be greater than or equal to the population of town B and the populations of both the towns at that time. QUESTION 10 Write a program that gets an integer, say n, by the user. The program than will get positive elements by the user until 0 is entered. When 0 is entered, the program will display the position of the last occurance of n. |
QUESTION 5 Write a C++ program that prints the prime numbers between 2 and 10000. Answer 1 - Amele Style :) int n = 2; Answer 2 -Elegance #include <iostream> |
Ellerine sağlık dostum :) Soru 5 i de atlattık.Çok az kaldır arkadaşlar lütfen yardımcı olun QUESTION 0 * Suppose that you are asked to develop a cell phone invoice calculator program. * There are two types of tariffs for users: * (1) the users that do not use any package are charged 0.15 TL/6 seconds * (2) the 'eco' package users will pay 19 TL fixed fee for first 50 minutes and 0.2 TL/6 seconds for extra talking time that exceeds 50 minutes * The program will get the total number of talking time in terms of minutes (double type) and then calculate and print the total amount that the user will pay for each tariff type. * Write the C++ source code of the above program. QUESTION 1 Write for and do-while structures to compute the following products. 1 x (1 / 3) x (1 / 5) x ….x (1 / (n/2)) where n is an integer entered by the user. QUESTION 2 Write a C++ program that gets a positive integer from the user. The number will be required until a positive number is entered. Find and print the factors of the entered number. QUESTION 3 #include<iostream> int main() { int i,j,k,n; cout << “How many rows?” << endl; cin >> n; for(i=n; i>0; i=i - 2) { cout << endl; for(k=(i+1)/2; k>0; --k) cout << “ “; for(j=1;j <= i; ++j) cout << “ &”; } } QUESTION 6 The value of π can be approximated by using the following series: Write a program that gets the value of n as a parameter and returns the estimated value of π. QUESTION 7 Let n = akak-1ak-2. . .a1a0 be an. Find and display the sum of digits of n (ak + ak-1 + ak-2 + …………… + a1 + a0) The number n will be entered by the user QUESTION 8 The population of a town A is less than the population of town B. However, the population of town A is growing faster than the population of town B. Write a program that prompts the user to enter the population and growth rate of each town. The program outputs after how many years the population of town A will be greater than or equal to the population of town B and the populations of both the towns at that time. QUESTION 10 Write a program that gets an integer, say n, by the user. The program than will get positive elements by the user until 0 is entered. When 0 is entered, the program will display the position of the last occurance of n. |
Okuğun okulu da biz okuyalım ? |
iyi geceler hepinize iki tane soru var yardım edersenız yarın sınavım var sevabına 1-)A[3][4] B[4][5] C=A*B , C=3*5 .. Calculate multiplication of 2 dimentional matries .. Soru bu yardımcı olur musunuz? (C++ ta) |
teşekkürlerr..
Bu mesajda bahsedilenler: @MrOwl