제가 혼자서 영상 안보고 복습을 하면서 코드를 작성해보니, 마지막 print문이 영상과는 다르게 나왔더라구요. 혹시나 이렇게 작성을 해도 문제가 없는지 궁금합니다. 또한 info와 speak에는 __info__처럼 언더바를 붙이지 않는데, 이유가 있을까요? class dog: species = 'first dog' def __init__(self, name, age): self.name = name self.age = age def info(self): return f"My name is {self.name}. I'm {self.age} old." def speak(self, sounds): return f"{self.name} barks {sounds}." a = dog('SooJin', 25) print(dog.info(a))
안녕하십니까. 강의 다 듣고 두번째 듣고 있습니다. 좋은 강의 감사합니다. 위 세개의 차이가 잘 이해가 안되는데, 제가 이해하고 있는게 맞는지 확인해주실수 있으신지요? 범위의 개념이 잘 이해가 되지 않아서... 아무튼.. 제가 이해한것은 다음과 같습니다. 범위를 세션으로 봤습니다. AddTransient : 호출될 때마다 새로운 인스턴스가 생성됨 AddScoped : 세션단위로 동일한 인스턴스가 제공됨. 즉, 같은 세션에서는 항상 동일한 객체가 제공되나, 다른 세션이 생성되었다면 그 세션내에서는 그 세션 전용의 객체가 생성되어 제공됨 AddSingleton : 세션과는 무관하게 애플리케이션 전체에서 하나의 객체만 생성되어 제공됨 위 내용이 맞는지요? 잘못 이해되었다면 가름침 부탁드립니다.. 감사합니다.
mvnw package 후 Success Build가 되어서 java -jar target/*.jar를 Terminal에서 실행하였으나, Error: Unable to access jarfile target/*.jar 이라는 에러가 나옵니다.. 해당 디렉토리에 jarfile을 확인해보니, 있음에도 불구하고 명령어 실행이 안됩니다.. 운영체제는 windows입니다. target 파일에 있는 jar 파일 명을 복사하여 명령어 입력하면 no main manifest attribute, in taget/*.jar 이라고 나오네요!
안녕하세요 항상 쉽고 명료한 강의 덕분에 너무나 잘 배우고 있습니다. 제가 계산기 코드를 따로 짜봤는데 빌드업이 되지 않아서 한 번 봐주실 수 있을까요? #include <stdio.h> void p(int plus); int main(void) { int a; int b; int plus = a + b; printf("숫자 두 개를 입력하시오\n"); scanf_s("%d %d", &a, &b); p(plus); } void p(int plus) { printf("a+b는 %d입니다.\n",plus); }
index.js:1 Warning: Encountered two children with the same key, `[object Object]`. Keys should be unique so that components maintain their identity across updates. Non-unique keys may cause children to be duplicated and/or omitted — the behavior is unsupported and could change in a future version. in div (at pages/index.js:28) in Home (at _app.js:28) in div (created by Context.Consumer) in Col (at AppLayout.js:38) in div (created by Context.Consumer) in Row (at AppLayout.js:29) in div (at AppLayout.js:19) in AppLayout (at _app.js:27) in Provider (at _app.js:21) in NodeBird (created by withRedux(NodeBird)) in withRedux(NodeBird) in Suspense (created by AppContainer) in Container (created by AppContainer) in AppContainer 이거 key를 바꿔야 되는건가여? https://github.com/hyunsokstar/node_bird_22/blob/master/front/pages/index.js 알려주시면 감사여 ~! ㄳㄳ~!
같은 서비스를 여러 나라에서 서비스중입니다. 소스는 같이 사용하나 서버나 db는 다른환경에서 운영중입니다. 타나라에서만 제공할 서비스에 컬럼을 계속해서 추가하는데 한국db테이블에도 불필요한 컬럼을 계속 추가해줘야하는 이슈가 생기고 있습니다. 혹시 이럴경우에 쉽게 해결할수 있는 방법이 있을까요?
firebase 연동 후 빌드시 빌드에러가 납니다. 1. android > build.gradle dependencies { classpath 'com.android.tools.build:gradle:3.3.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin: $kotlin_version " classpath 'com.google.gms:google-services:4.2.0' } 2. android > app > build.gradle defaultConfig { // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). applicationId "com.vampireahn.instagram_clon" minSdkVersion 16 targetSdkVersion 28 multiDexEnabled true versionCode flutterVersionCode.toInteger() versionName flutterVersionName testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7: $kotlin_version " testImplementation 'junit:junit:4.12' androidTestImplementation 'androidx.test:runner:1.1.1' androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1' implementation 'com.google.firebase:firebase-core:16.0.7' } apply plugin : 'com.google.gms.google-services' 3. android > gradle.properties org.gradle.jvmargs = -Xmx1536M android.useAndroidX = true android.enableJetifier = true 위와같이 설정 후 빌드를 하면 * Error running Gradle: ProcessException: Process "/Users/an-yongjae/FlutterProjects/instagram_clon/instagram_clon/android/gradlew" exited abnormally: > Configure project :app registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection) WARNING: API 'variant.getJavaCompile()' is obsolete and has been replaced with 'variant.getJavaCompileProvider()'. It will be removed at the end of 2019. For more information, see https://d.android.com/r/tools/task-configuration-avoidance. To determine what is calling variant.getJavaCompile(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace. WARNING: API 'variant.getMergeAssets()' is obsolete and has been replaced with 'variant.getMergeAssetsProvider()'. It will be removed at the end of 2019. For more information, see https://d.android.com/r/tools/task-configuration-avoidance. To determine what is calling variant.getMergeAssets(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace. WARNING: API 'variantOutput.getProcessResources()' is obsolete and has been replaced with 'variantOutput.getProcessResourcesProvider()'. It will be removed at the end of 2019. For more information, see https://d.android.com/r/tools/task-configuration-avoidance. To determine what is calling variantOutput.getProcessResources(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace. ********************************************************* WARNING: This version of image_picker will break your Android build if it or its dependencies aren't compatible with AndroidX. See https://goo.gl/CP92wY for more information on the problem and how to fix it. This warning prints for all Android build failures. The real root cause of the error may be unrelated. ********************************************************* FAILURE: Build failed with an exception. * What went wrong: The Android Gradle plugin supports only Kotlin Gradle plugin version 1.3.0 and higher. The following dependencies do not satisfy the required version: root project 'android' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.2.71 * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 5s Command: /Users/an-yongjae/FlutterProjects/instagram_clon/instagram_clon/android/gradlew app:properties Finished with error: Please review your Gradle project setup in the android/ folder. 와 같이 빌드 에러가 납니다. 어떻게 수정을 해야 하는지 조언 부탁 드립니다.
포탄을 쏘고 움직이고 포탄을 쏘면 메모리 릭이 생기신다고 하셨는데 왜 메모리릭이 생기는지 잘이해가 안갑니다. 15분에서 힌트 주신다면서 총알이 있는 상태에서 또 스페이스를 누르면 원래 나가던 총알이 딜리트가 안된상태에서 뉴 불릿으로 새롭게 만들어지면서 메모리릭이 생기게 된다 이 이유 때문인건가요? 아니면 다른 문제 인건가요? 그리고 혹시 이런 부분에서 메모리 릭이 실시간으로 나고있는지 아닌지 확인 하는 방법이 따배c++에서 비쥬얼 스튜디오로 프로파일링 하기 이부분을 참고하면 되는건가요?
[코드] import csv def aetKev(item): # 데이터 정렬코드 return item[1] command_data=[] # 파일 읽어오기 코 with open("command_data.csv","r") as csvfile: spamreader=csv.reader(csvfile, delimiter=',', quotechar='"') for row in spamreader: command_data.append(row) print(len(command_data)) [실행에러] C:\workspace>python dict.py Traceback (most recent call last): File "dict.py", line 8, in <module> for row in spamreader: UnicodeDecodeError: 'cp949' codec can't decode byte 0x80 in position 590: illegal multibyte sequence